-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revive CI #15
Revive CI #15
Changes from all commits
f549364
ebd797c
b97a926
424b58b
9452271
6b63355
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"pr": { | ||
"ci": { | ||
"include": [ | ||
{ | ||
"php": "8.0", | ||
"sylius": "1.12.*", | ||
"symfony": "5.4.*", | ||
"mysql": "8.0" | ||
}, | ||
{ | ||
"php": "8.3", | ||
"sylius": "1.13.*", | ||
"symfony": "6.4.*", | ||
"mysql": "8.0" | ||
} | ||
] | ||
}, | ||
"daily": { | ||
"php": ["8.0", "8.3"], | ||
"sylius": ["1.12.*", "1.13.*"], | ||
"symfony": ["5.4.*", "6.4.*"], | ||
"mysql": ["8.0"] | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Continuous Integration (Daily) | ||
|
||
on: | ||
schedule: | ||
- | ||
cron: "0 3 * * *" # Run every day at 3am | ||
workflow_dispatch: ~ | ||
|
||
concurrency: | ||
group: ci-${{ github.workflow }}-${{ github.ref }}-minimal | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
ci: | ||
name: CI | ||
uses: ./.github/workflows/ci.yaml | ||
with: | ||
type: "daily" |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Continuous Integration (PR) | ||
|
||
on: | ||
pull_request: | ||
paths-ignore: | ||
- ".platform/**" | ||
- "*.md" | ||
push: | ||
branches: | ||
- main | ||
workflow_dispatch: ~ | ||
|
||
concurrency: | ||
group: ci-${{ github.workflow }}-${{ github.ref }}-minimal | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
ci: | ||
name: CI | ||
uses: ./.github/workflows/ci.yaml | ||
with: | ||
type: "pr" |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?php | ||
|
||
use ShipMonk\ComposerDependencyAnalyser\Config\Configuration; | ||
use ShipMonk\ComposerDependencyAnalyser\Config\ErrorType; | ||
|
||
$config = new Configuration(); | ||
|
||
return $config | ||
//// Adjusting scanned paths | ||
->addPathToScan(__DIR__ . '/src', isDev: false) | ||
->disableComposerAutoloadPathScan() // disable automatic scan of autoload & autoload-dev paths from composer.json | ||
->ignoreErrorsOnPackage('sylius/sylius', [ErrorType::DEV_DEPENDENCY_IN_PROD]) | ||
->ignoreErrorsOnPackage('sylius/core-bundle', [ErrorType::UNUSED_DEPENDENCY]) | ||
Comment on lines
+12
to
+13
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For the same reason as mentioned in |
||
; |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,8 +5,7 @@ | |
"license": "MIT", | ||
"autoload": { | ||
"psr-4": { | ||
"CommerceWeavers\\SyliusTpayPlugin\\": "src/", | ||
"Tests\\CommerceWeavers\\SyliusTpayPlugin\\Behat\\": "tests/Behat" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It was unused |
||
"CommerceWeavers\\SyliusTpayPlugin\\": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
|
@@ -18,13 +17,20 @@ | |
"require": { | ||
"php": "^8.0", | ||
"sylius/core-bundle": "^1.12", | ||
"tpay-com/tpay-openapi-php": "^1.8" | ||
"tpay-com/tpay-openapi-php": "^1.8", | ||
"payum/core": "^1.7", | ||
"sylius/resource-bundle": "^1.10", | ||
"symfony/config": "5.4.* || ^6.0", | ||
"symfony/dependency-injection": "5.4.* || ^6.0", | ||
"symfony/form": "5.4.* || ^6.0", | ||
"symfony/http-foundation": "5.4.* || ^6.0", | ||
"symfony/http-kernel": "5.4.* || ^6.0", | ||
"symfony/routing": "5.4.* || ^6.0" | ||
}, | ||
"conflict": { | ||
"sylius/sylius": "<1.12" | ||
}, | ||
"require-dev": { | ||
"alphpaca/monocle-constraint": "^0.1", | ||
"phpspec/prophecy-phpunit": "^2.2", | ||
"phpstan/extension-installer": "^1.0", | ||
"phpstan/phpstan": "^1.8.1", | ||
|
@@ -33,32 +39,32 @@ | |
"phpstan/phpstan-webmozart-assert": "^1.2.0", | ||
"phpunit/phpunit": "^9.5", | ||
"polishsymfonycommunity/symfony-mocker-container": "^1.0", | ||
"shipmonk/composer-dependency-analyser": "^1.7", | ||
"sylius-labs/coding-standard": "^4.2", | ||
"sylius/sylius": "^1.12", | ||
"symfony/browser-kit": "^5.4 || ^6.0", | ||
"symfony/debug-bundle": "^5.4 || ^6.0", | ||
"symfony/dotenv": "^5.4 || ^6.0", | ||
"symfony/flex": "^2.4", | ||
"symfony/intl": "^5.4 || ^6.0", | ||
"symfony/monolog-bundle": "^3.10", | ||
"symfony/web-profiler-bundle": "^5.4 || ^6.0" | ||
}, | ||
"config": { | ||
"sort-packages": true, | ||
"allow-plugins": { | ||
"alphpaca/monocle-constraint": true, | ||
"dealerdirect/phpcodesniffer-composer-installer": false, | ||
"phpstan/extension-installer": true, | ||
"symfony/flex": true, | ||
"symfony/runtime": true | ||
} | ||
}, | ||
"extra": { | ||
"branch-alias": { | ||
"dev-main": "1.0-dev" | ||
}, | ||
"monocle": { | ||
"constraint": { | ||
"symfony/symfony": "5.4.*" | ||
} | ||
"symfony": { | ||
"require": "5.4.*" | ||
} | ||
}, | ||
"scripts": { | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,9 +5,19 @@ | |
namespace CommerceWeavers\SyliusTpayPlugin; | ||
|
||
use Sylius\Bundle\CoreBundle\Application\SyliusPluginTrait; | ||
use Symfony\Component\HttpKernel\Bundle\AbstractBundle; | ||
use Symfony\Component\HttpKernel\Bundle\Bundle; | ||
|
||
final class CommerceWeaversSyliusTpayPlugin extends AbstractBundle | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It wasn't present in Symfony 5.4 :< |
||
final class CommerceWeaversSyliusTpayPlugin extends Bundle | ||
{ | ||
use SyliusPluginTrait; | ||
|
||
public function getPath(): string | ||
{ | ||
if (!isset($this->path)) { | ||
$reflected = new \ReflectionObject($this); | ||
$this->path = \dirname($reflected->getFileName(), 2); | ||
} | ||
|
||
return $this->path; | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've already spent too much time on figuring out why the configuration wasn't working, so I'm skipping it for now. In general, as we install all deps we're getting false-positives. We need to extract it to a separate job, download only non-dev deps, and then run it.