* sort map keys when generating asserts
keep cstest for generic helper functions this also avoids circular imports in test files