Timeline for How to create a unit test for a class which uses a trait?
Current License: CC BY-SA 3.0
7 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jun 1, 2018 at 18:48 | comment | added | ssibal | Read both links: It states nowhere, that it's a good general approach, when you are using a trait (like StringTranslation) it would be a good approach to implement ContainerFactoryPLuginInterface. In the original question I state nowhere that am only interested in plugin classes. | |
Jun 1, 2018 at 7:36 | comment | added | Eyal | api.drupal.org/api/drupal/… | |
Jun 1, 2018 at 7:21 | comment | added | Eyal | drupal.org/docs/8/phpunit/agile-unit-testing | |
Jun 1, 2018 at 7:17 | comment | added | ssibal | Can you please attach then a link in your answer? | |
Jun 1, 2018 at 7:17 | comment | added | Eyal | This is what the Drupal documentation recommends. | |
Jun 1, 2018 at 6:45 | comment | added | ssibal | I strongly disagree to implement something in your unit just to able test it. | |
Nov 19, 2016 at 0:27 | history | answered | Eyal | CC BY-SA 3.0 |