function it_should_encode_data_using_the_parser(Parser $parser) { $parser->decode([])->willReturn([]); $parser->encode(null)->shouldBeCalled(); $this->beConstructedWith([], $parser); $this->get('test'); }