Add unit tests for featureMap javascript code