Thanks for the work on this. We discussed many superficial changes on IRC, and you've made corresponding improvements: separate creation of complex expected values from comparisons to actual values. Better not import twisted.trial.unittest under that name since it leads to confusion with the global unittest. Use a list comprehension instead of a loop calling a function. Use transaction instead of layer.txn. Bear our syntax guidelines in mind when initializing dicts.
Discussed but not changed:
* Testing the logic without Twisted. Complete the overhaul first, then be clever.
* Extracting more of the unit test setup into helpers to make the tests shorter. First see what parameterization would be needed as the tests grow.
Thanks for the work on this. We discussed many superficial changes on IRC, and you've made corresponding improvements: separate creation of complex expected values from comparisons to actual values. Better not import twisted. trial.unittest under that name since it leads to confusion with the global unittest. Use a list comprehension instead of a loop calling a function. Use transaction instead of layer.txn. Bear our syntax guidelines in mind when initializing dicts.
Discussed but not changed:
* Testing the logic without Twisted. Complete the overhaul first, then be clever.
* Extracting more of the unit test setup into helpers to make the tests shorter. First see what parameterization would be needed as the tests grow.