Added tests to coder, fix tok automap to secondary