This should make judging much easier.
Fix is confirmed with the existing test case (which is updated to
match the new behavior).
- this.state.ambiguities = Object.values(word_map);
+ this.state.ambiguities = Object.values(word_map).sort((a,b) => {
+ return a.toLowerCase().localeCompare(b.toLowerCase());
+ });
this.broadcast_event_object('ambiguities', this.state.ambiguities);
}
this.broadcast_event_object('ambiguities', this.state.ambiguities);
}
TEST "Received all unique words"
# echo here is to strip newlines
result=$(echo $(empathy_ambiguities $alice))
TEST "Received all unique words"
# echo here is to strip newlines
result=$(echo $(empathy_ambiguities $alice))
-test "$result" = '"sun" "sand" "water" "people" "sands" "SunLight" "towels" "SunShine" "Grains of Sand" "wafer"'
+test "$result" = '"Grains of Sand" "people" "sand" "sands" "sun" "SunLight" "SunShine" "towels" "wafer" "water"'
TEST_END
TEST "Submit word groups from alice"
TEST_END
TEST "Submit word groups from alice"