Skip to content

Commit

Permalink
workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
sreichel committed Dec 14, 2024
1 parent 1563f5a commit b0d4ddf
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 34 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/rector.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: PHP-CS-Fixer
name: Rector

on:
push:
Expand All @@ -9,7 +9,7 @@ on:

jobs:
php-cs-fixer:
name: Validation
name: Rector
runs-on: [ubuntu-latest]

steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-magento-open-source.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ jobs:
run: echo "N98_MAGERUN_TEST_MAGENTO_ROOT=${{ github.workspace }}/magento" >> $GITHUB_ENV

- name: Run tests
run: php -f vendor/bin/phpunit
run: php vendor/bin/phpunit --configuration .phpunit.dist.xml
env:
COMPOSER_VENDOR_PATH : "${{ github.workspace }}/magento/vendor"

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-openmage-20.0.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ jobs:
run: echo "N98_MAGERUN_TEST_MAGENTO_ROOT=${{ github.workspace }}/magento" >> $GITHUB_ENV

- name: Run tests
run: php -f vendor/bin/phpunit
run: php vendor/bin/phpunit --configuration .phpunit.dist.xml
env:
COMPOSER_VENDOR_PATH : "${{ github.workspace }}/magento/vendor"

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-openmage-20.1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ jobs:
run: echo "N98_MAGERUN_TEST_MAGENTO_ROOT=${{ github.workspace }}/magento" >> $GITHUB_ENV

- name: Run tests
run: php -f vendor/bin/phpunit
run: php vendor/bin/phpunit --configuration .phpunit.dist.xml
env:
COMPOSER_VENDOR_PATH : "${{ github.workspace }}/magento/vendor"

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-openmage-20.10.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ jobs:
run: echo "N98_MAGERUN_TEST_MAGENTO_ROOT=${{ github.workspace }}/magento" >> $GITHUB_ENV

- name: Run tests
run: php -f vendor/bin/phpunit
run: php vendor/bin/phpunit --configuration .phpunit.dist.xml
env:
COMPOSER_VENDOR_PATH : "${{ github.workspace }}/magento/vendor"

Expand Down
23 changes: 0 additions & 23 deletions .php_cs

This file was deleted.

6 changes: 3 additions & 3 deletions src/N98/Magento/Command/System/Setup/RemoveCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,13 @@ protected function execute(InputInterface $input, OutputInterface $output): int

public function removeSetupResource(string $moduleName, string $setupResource, OutputInterface $output): void
{
$mageCoreModelAbstract = $this->getMageCoreResource();
$writeAdapter = $mageCoreModelAbstract->getConnection('core_write');
$mageCoreModelResource = $this->getMageCoreResource();
$writeAdapter = $mageCoreModelResource->getConnection('core_write');
if (!$writeAdapter) {
throw new RuntimeException('Database not configured');
}

$table = $mageCoreModelAbstract->getTableName('core_resource');
$table = $mageCoreModelResource->getTableName('core_resource');

if ($writeAdapter->delete($table, ['code = ?' => $setupResource]) > 0) {
$output->writeln(
Expand Down
4 changes: 2 additions & 2 deletions tests/N98/Util/AutoloadHandlerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
/**
* Class AutoloadHandlerTest
*
* @covers \N98\Util\AutoloadHandler
* @covers AutoloadHandler
* @package N98\Util
*
* @author Tom Klingenberg <https://github.com/ktomk>
Expand Down Expand Up @@ -40,7 +40,7 @@ public function testCreation()
public function testNoRegistrationOnCreation()
{
$this->expectException(Error::class);
$this->expectExceptionMessage('Typed property N98\Util\AutoloadHandler::$splRegistered must not be accessed before initialization');
$this->expectExceptionMessage('Typed property ' . AutoloadHandler::class . '::$splRegistered must not be accessed before initialization');

$handler = $this->create(null, AutoloadHandler::NO_AUTO_REGISTER);
$handler->disable(); // assertions require a disabled handler b/c of exceptions
Expand Down

0 comments on commit b0d4ddf

Please sign in to comment.