public function it_loads_parses_and_writes_files(NodeWalker $walker, Loader $loader, Writer $writer) { $loader->load(__DIR__)->shouldBeCalled()->willReturn([]); $walker->walk([])->shouldBeCalled()->willReturn([]); $writer->write([])->shouldBeCalled(); $this->process(__DIR__); }
/** * {@inheritdoc} */ public function process($resource) { $nodes = $this->loader->load($resource); $nodes = $this->walker->walk($nodes); return $this->writer->write($nodes); }