Test case for tricky JS