getCountryCode maps some country codes to each other to match GeoGuessr's streak behaviour, this adds a few tests so we can make sure that it actually does do the same thing.
Also some tests for selectFlag, I noticed it wasn't giving the british flag anymore for !flag uk. Tweaking the order in the names list makes match-sorter use the correct flag again.
Since the socket change added an import statement in GameHandler.js, parcel treats it as an ES module. I changed the other requires to match so both parcel and typescript are happy with it.
I also added a github actions workflow so tests and typechecks are run on PRs. we dont need to take it super seriously probably but it's nice as an indication.
getCountryCode
maps some country codes to each other to match GeoGuessr's streak behaviour, this adds a few tests so we can make sure that it actually does do the same thing.Also some tests for
selectFlag
, I noticed it wasn't giving the british flag anymore for!flag uk
. Tweaking the order in thenames
list makesmatch-sorter
use the correct flag again.Since the socket change added an
import
statement in GameHandler.js, parcel treats it as an ES module. I changed the other requires to match so both parcel and typescript are happy with it.I also added a github actions workflow so tests and typechecks are run on PRs. we dont need to take it super seriously probably but it's nice as an indication.