Correct test and fix when ID passed last
Migrate tests to Mocha/jsdom