Skip to content

Commit

Permalink
Merge branch 'b-7.0.x-root-experiment' into b-7.0.x
Browse files Browse the repository at this point in the history
  • Loading branch information
Sieg committed Sep 20, 2024
2 parents ffd4b19 + 779fcdf commit 655ffbe
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 25 deletions.
28 changes: 16 additions & 12 deletions .github/fresh-advance/module-invoice.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,40 @@
install_shop_with_modules:
install:
cache:
prepared_shop: false
git:
repository: 'Fresh-Advance/Invoice'
ref: &ref '{{ .Github.RefName }}'
shop_url: 'https://github.com/Fresh-Advance/Invoice.git'
shop_ref: *ref
composer:
root_url: ''
transform: |
{
"require": {
"oxid-esales/oxideshop-ce": "{{ .Data.global.composer.dev_ref }}",
"oxid-esales/twig-admin-theme": "{{ .Data.global.composer.dev_ref }}",
"oxid-esales/twig-theme": "{{ .Data.global.composer.dev_ref }}",
"oxid-esales/developer-tools": "{{ .Data.global.composer.dev_ref }}",
"fresh-advance/invoice": "dev-{{ .Github.RefName }}"
},
"repositories": {
"fresh-advance/invoice": {
"type": "git",
"url": "https://github.com/Fresh-Advance/Invoice.git"
}
"oxid-esales/twig-theme": "{{ .Data.global.composer.dev_ref }}"
}
}
custom_script_container: |
vendor/bin/oe-console oe:database:reset --db-host=mysql --db-port=3306 --db-name=example --db-user=root --db-password=root --force
vendor/bin/oe-console oe:module:install ./
vendor/bin/oe-console oe:module:activate fa_invoice
vendor/bin/oe-console oe:theme:activate twig
install_shop_with_modules:
composer:
root_url: ''

runscript: &runscript
matrix:
script: |
[
"fa_invoice:tests-clover",
"fa_invoice:tests-codeception",
]
fa_invoice:
path: 'vendor/fresh-advance/invoice'
path: ''

runslim:
<<: *runscript
Expand All @@ -45,7 +49,7 @@ runslim:
sonarcloud:
matrix:
testplan: '["-"]'
strip_path: '/var/www/vendor/fresh-advance/invoice/'
strip_path: '/var/www/'
project_name: 'Invoice'
project_key: 'Fresh-Advance_Invoice'
organization: 'fresh-advance'
Expand Down
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/composer.lock
/Coverage
/source
/var
/vendor
/vendor
18 changes: 12 additions & 6 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,18 @@
"codeception/module-filesystem": "^3.0",
"codeception/module-webdriver": "^3.1",
"oxid-esales/codeception-modules": "dev-b-7.0.x",
"oxid-esales/codeception-page-objects": "dev-b-7.0.x"
"oxid-esales/codeception-page-objects": "dev-b-7.0.x",
"oxid-esales/developer-tools": "dev-b-7.0.x"
},
"autoload": {
"psr-4": {
"FreshAdvance\\Invoice\\": "./src",
"FreshAdvance\\Invoice\\Tests\\": "./tests"
"FreshAdvance\\Invoice\\": "./src"
}
},
"autoload-dev": {
"psr-4": {
"FreshAdvance\\Invoice\\Tests\\": "./tests",
"OxidEsales\\EshopCommunity\\Tests\\": "./vendor/oxid-esales/oxideshop-ce/tests"
}
},
"scripts": {
Expand All @@ -55,17 +61,17 @@
],

"tests-unit": "vendor/bin/phpunit --bootstrap=/var/www/source/bootstrap.php --config=tests/",
"tests-coverage": "XDEBUG_MODE=coverage vendor/bin/phpunit --coverage-text --bootstrap=/var/www/source/bootstrap.php --config=tests/ --coverage-html=tests/result/coverage",
"tests-coverage": "XDEBUG_MODE=coverage vendor/bin/phpunit --coverage-text --bootstrap=/var/www/source/bootstrap.php --config=tests/ --coverage-html=tests/Reports/CoverageHtml",
"tests-clover": "XDEBUG_MODE=coverage vendor/bin/phpunit --coverage-text --coverage-clover=tests/Reports/coverage_fa_invoice.xml --bootstrap=/var/www/source/bootstrap.php --config=tests/",

"tests-codeception": [
"Composer\\Config::disableProcessTimeout",
"MODULE_IDS=fa_invoice SHOP_ROOT_PATH=/var/www/ vendor/bin/codecept run Acceptance -c tests/codeception.yml"
"MODULE_IDS=fa_invoice vendor/bin/codecept run Acceptance -c tests/codeception.yml"
]
},
"config": {
"allow-plugins": {
"oxid-esales/oxideshop-composer-plugin": false,
"oxid-esales/oxideshop-composer-plugin": true,
"oxid-esales/oxideshop-unified-namespace-generator": true
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/Codeception/Acceptance.suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ modules:
paths:
- Application/views/admin_twig
- Application/views/twig
- ../vendor/fresh-advance/invoice/views/admin_twig
- ../views/admin_twig
- \OxidEsales\Codeception\Module\OxideshopModules

step_decorators:
Expand Down
4 changes: 0 additions & 4 deletions tests/Codeception/Config/params.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,6 @@
use OxidEsales\Codeception\Module\Database\DatabaseDefaultsFileGenerator;
use Symfony\Component\Filesystem\Path;

if ($shopRootPath = getenv('SHOP_ROOT_PATH')){
require_once($shopRootPath . '/source/bootstrap.php');
}

$facts = new Facts();
return [
'SHOP_URL' => $facts->getShopUrl(),
Expand Down
2 changes: 2 additions & 0 deletions tests/Reports/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
*
!.gitignore

0 comments on commit 655ffbe

Please sign in to comment.