Nimut / testing-framework

TYPO3 testing framework that provides base classes and configuration for PHPUnit tests
GNU General Public License v2.0
52 stars 25 forks source link

[FEATURE] Copy ExtensionTestEnvironment from TYPO3 testing framework #134

Closed simonschaufi closed 4 years ago

simonschaufi commented 4 years ago

This class is added as composer "script" in TYPO3 extensions:

"scripts": {
     "post-autoload-dump": [
          "@prepare-extension-test-environment"
     ],
     "prepare-extension-test-structure": [
          "Nimut\\TestingFramework\\Composer\\ExtensionTestEnvironment::prepare"
     ]
},
IchHabRecht commented 4 years ago

Hi @simonschaufi,

Thank you for your pull request. I try to work on that in the next couple of days. First thoughts: I don't want the command to be run by default but just offer extensions to might use it. Secondly I think the paths need to be adjusted as the directory structure from nimut is slightly different to the typo3 ones. But I will check this again.

simonschaufi commented 4 years ago

The post-autoload-dump is not added by default. The extension developer has to do this manually. Yes, Nimut internally has different directory structure but this is not for Nimut but for the extension that needs to be tested and there the paths are always the same but let my confirm that myself again just to be 100% sure.

IchHabRecht commented 4 years ago

Hi @simonschaufi,

Sorry, I mixed up your pull request and the comment in this issue. But using DIR is based on the nimut structure, not the extensions one.

simonschaufi commented 4 years ago

@IchHabRecht It was not my intention to give you so much work to refactor everything. Doesn't it make sense to stay close to the TYPO3 testing framework? Thank you so much for all the work you put into this :orange_heart:

simonschaufi commented 4 years ago

:tada: Thank you!