Unit tests for testing JS functions