-
Notifications
You must be signed in to change notification settings - Fork 17
Open
Description
Hi, I was running the "make test" target to see if a change I made was passing.
However I found that the test for multidropdownblank was failing.
The function returns [[]] instead of the expected [].
test_multidropdownblank() ->
{
fun() -> wf:set_multiple(multiple, []) end,
- fun() -> wf:qs(multiple) == [] end
+ fun() -> wf:qs(multiple) == [[]] end
}.
https://github.com/nitrogen/NitrogenProject.com/blob/master/src/tests/tests_simplecontrols.erl#L75
The question now becomes - what is wf:qs supposed to return if there is no result?
It seems that:
- if the element with id=multiple is ON screen - and data is selected ( "1","3" ) - it returns ["1","3"]
- if the element with id=multiple is NOT ON screen - it returns []
- if the element with id=multiple is ON screen - without any selection - it returns [[]]
Could you confirm my understanding?
Kind regards,
Fabian
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels