See for example mode/javascript/test.js. The test/mode-test.js file defines a framework for writing out pieces of code annotated with expected token types. If you write a test file in that style and have test/index.html include it, the tests will be run as part of the test suite.
< and > have no special interpretation in the mode-test minilanguage, so I don’t know what might be going wrong there. Maybe console.log the output of parseTokens in mode_test.js and wee if it differs from what you’d expect.