Skip to content

Commit

Permalink
add test loadFixture methods live template
Browse files Browse the repository at this point in the history
  • Loading branch information
jalogut committed Mar 28, 2018
1 parent 8e587ac commit d4bad9d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
9 changes: 8 additions & 1 deletion Preferences/templates/StmpflMagento2.xml
Original file line number Diff line number Diff line change
Expand Up @@ -577,7 +577,7 @@
<option name="PHP" value="true" />
</context>
</template>
<template name="2magento test fixture function" value="/**&#10; * @magentoAppIsolation enabled&#10; * @magentoDbIsolation enabled&#10; * @magentoDataFixture $fixtureFile$&#10; */&#10;public function test$name$()&#10;{&#10; // $this-&gt;assert...&#10;}" description="" toReformat="false" toShortenFQNames="true">
<template name="2magento test annotation fixture" value="/**&#10; * @magentoAppIsolation enabled&#10; * @magentoDbIsolation enabled&#10; * @magentoDataFixture /../../../../../../dev/tests/integration/testsuite/Magento/$fixtureFile$.php&#10; */&#10;public function test$name$()&#10;{&#10; // $this-&gt;assert...&#10;}" description="" toReformat="false" toShortenFQNames="true">
<variable name="fixtureFile" expression="" defaultValue="" alwaysStopAt="true" />
<variable name="name" expression="" defaultValue="" alwaysStopAt="true" />
<context>
Expand Down Expand Up @@ -763,4 +763,11 @@
<option name="PHP" value="true" />
</context>
</template>
<template name="2magento test loadFixture methods" value="public static function loadFixture()&#10;{&#10; include __DIR__ . '/../../../../../../dev/tests/integration/testsuite/Magento/$fileSubPath$.php';&#10;}&#10;&#10;public static function loadFixtureRollback()&#10;{&#10; include __DIR__ . '/../../../../../../dev/tests/integration/testsuite/Magento/$fileSubPath$_rollback.php';&#10;}&#10;&#10;/**&#10; * @magentoAppIsolation enabled&#10; * @magentoDbIsolation enabled&#10; * @magentoDataFixture loadFixture&#10; */&#10;public function test$name$()&#10;{&#10; // $this-&gt;assert...&#10;}" description="" toReformat="false" toShortenFQNames="true">
<variable name="fileSubPath" expression="" defaultValue="" alwaysStopAt="true" />
<variable name="name" expression="" defaultValue="" alwaysStopAt="true" />
<context>
<option name="PHP" value="true" />
</context>
</template>
</templateSet>
5 changes: 3 additions & 2 deletions docs/liveTemplates.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
* 2magento plugin around
* 2magento test objectManager
* 2magento test integration
* 2magento test fixture function
* 2magento test annotation fixture
* 2magento test dataProvider function
* 2magento customer add attribute
* 2magento field wysiwyg simple
Expand Down Expand Up @@ -104,4 +104,5 @@
* 2magento test integration controller
* 2magento test unit
* 2magento test command execute method
* 2magento test email
* 2magento test email
* 2magento test loadFixture methods

0 comments on commit d4bad9d

Please sign in to comment.