workshop-drupal-automated-testing icon indicating copy to clipboard operation
workshop-drupal-automated-testing copied to clipboard

Instructions for "18.4 Mocking the article node" are incomplete

Open johncook opened this issue 4 years ago • 0 comments

After mocking the node the unit test for the Post entity still fails. This is because the mocked item isn't passed into the constructor.

For clarity the code change to do this should be added.

- $post = new Post();
+ $post = new Post($node);

johncook avatar Oct 18 '21 10:10 johncook