Tests: Rewrite object factory.