Related to #224. Fix failing tests.