From 49236dfed2b03313142d752716c3a085ade51cfb Mon Sep 17 00:00:00 2001 From: Rana Muhammad Irshad Date: Fri, 24 May 2024 14:47:24 +0200 Subject: [PATCH 1/4] Update module and github actins, DEV-569 --- .github/workflows/coding-standard.yml | 8 +- .github/workflows/integration.yml | 355 +------------------------- .github/workflows/mess-detector.yml | 6 +- .github/workflows/phpstan.yml | 11 +- composer.json | 2 +- 5 files changed, 15 insertions(+), 367 deletions(-) diff --git a/.github/workflows/coding-standard.yml b/.github/workflows/coding-standard.yml index fa358ed..37ecccb 100644 --- a/.github/workflows/coding-standard.yml +++ b/.github/workflows/coding-standard.yml @@ -2,9 +2,5 @@ name: ExtDN M2 Coding Standard on: [push, pull_request] jobs: - static: - name: M2 Coding Standard - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: extdn/github-actions-m2/magento-coding-standard@master + phpcs: + uses: customgento/m2-github-actions/.github/workflows/coding-standard.yml@main diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index dd0b72e..2b60213 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -1,351 +1,10 @@ name: ExtDN M2 Integration Tests on: [ push, pull_request ] +env: + HYVA_GITLAB_TOKEN: ${{ secrets.HYVA_GITLAB_TOKEN }} jobs: - integration-tests-2-4-4-p6-8-1: - name: Magento 2.4.4-p6 PHP 8.1 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.4-p6 (PHP 8.1) - uses: extdn/github-actions-m2/magento-integration-tests/8.1@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.4-p6' - composer_version: '2' - integration-tests-2-4-4-p6-7-4: - name: Magento 2.4.4-p6 PHP 7.4 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.4-p6 (PHP 7.4) - uses: extdn/github-actions-m2/magento-integration-tests/7.4@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.4-p6' - composer_version: '2' - integration-tests-2-4-4-p5-7-4: - name: Magento 2.4.4-p5 PHP 7.4 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.4-p5 (PHP 7.4) - uses: extdn/github-actions-m2/magento-integration-tests/7.4@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.4-p5' - composer_version: '2' - integration-tests-2-4-4-p5-8-1: - name: Magento 2.4.4-p5 PHP 8.1 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.4-p5 (PHP 8.1) - uses: extdn/github-actions-m2/magento-integration-tests/8.1@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.4-p5' - composer_version: '2' - integration-tests-2-4-5-p5-8-1: - name: Magento 2.4.5-p5 PHP 8.1 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.5-p5 (PHP 8.1) - uses: extdn/github-actions-m2/magento-integration-tests/8.1@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.5-p5' - composer_version: '2' - integration-tests-2-4-5-p5-7-4: - name: Magento 2.4.5-p5 PHP 7.4 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.5-p5 (PHP 7.4) - uses: extdn/github-actions-m2/magento-integration-tests/7.4@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.5-p5' - composer_version: '2' - integration-tests-2-4-5-p4-7-4: - name: Magento 2.4.5-p4 PHP 7.4 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.5-p4 (PHP 7.4) - uses: extdn/github-actions-m2/magento-integration-tests/7.4@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.5-p4' - composer_version: '2' - integration-tests-2-4-5-p4-8-1: - name: Magento 2.4.5-p4 PHP 8.1 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.5-p4 (PHP 8.1) - uses: extdn/github-actions-m2/magento-integration-tests/8.1@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.5-p4' - composer_version: '2' - integration-tests-2-4-6-p3-8-1: - name: Magento 2.4.6-p3 PHP 8.1 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.6-p3 (PHP 8.1) - uses: extdn/github-actions-m2/magento-integration-tests/8.1@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.6-p3' - composer_version: '2' - integration-tests-2-4-6-p3-8-2: - name: Magento 2.4.6-p3 PHP 8.2 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.6-p3 (PHP 8.2) - uses: extdn/github-actions-m2/magento-integration-tests/8.2@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.6-p3' - composer_version: '2' - integration-tests-2-4-6-p2-8-2: - name: Magento 2.4.6-p2 PHP 8.2 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.6-p2 (PHP 8.2) - uses: extdn/github-actions-m2/magento-integration-tests/8.2@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.6-p2' - composer_version: '2' - integration-tests-2-4-6-p2-8-1: - name: Magento 2.4.6-p2 PHP 8.1 Integration Tests - runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: root - ports: - - 3306:3306 - options: --tmpfs /tmp:rw --tmpfs /var/lib/mysql:rw --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 - es: - image: docker.io/wardenenv/elasticsearch:7.8 - ports: - - 9200:9200 - env: - 'discovery.type': single-node - 'xpack.security.enabled': false - ES_JAVA_OPTS: "-Xms64m -Xmx512m" - options: --health-cmd="curl localhost:9200/_cluster/health?wait_for_status=yellow&timeout=60s" --health-interval=10s --health-timeout=5s --health-retries=3 - steps: - - uses: actions/checkout@v4 - - name: M2 Integration Tests with Magento 2 Version 2.4.6-p2 (PHP 8.1) - uses: extdn/github-actions-m2/magento-integration-tests/8.1@master - with: - module_name: CustomGento_CliTaxEditor - composer_name: customgento/module-cli-tax-editor-m2 - ce_version: '2.4.6-p2' - composer_version: '2' + integration: + uses: customgento/m2-github-actions/.github/workflows/integration.yml@main + with: + module_name: CustomGento_CliTaxEditor + composer_name: customgento/module-cli-tax-editor-m2 diff --git a/.github/workflows/mess-detector.yml b/.github/workflows/mess-detector.yml index 23e9417..cf9e5b5 100644 --- a/.github/workflows/mess-detector.yml +++ b/.github/workflows/mess-detector.yml @@ -3,8 +3,4 @@ on: [push, pull_request] jobs: phpmd: - name: M2 Mess Detector - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: extdn/github-actions-m2/magento-mess-detector@master + uses: customgento/m2-github-actions/.github/workflows/mess-detector.yml@main diff --git a/.github/workflows/phpstan.yml b/.github/workflows/phpstan.yml index 37e324d..67cc71b 100644 --- a/.github/workflows/phpstan.yml +++ b/.github/workflows/phpstan.yml @@ -3,10 +3,7 @@ on: [push, pull_request] jobs: phpstan: - name: M2 PHPStan - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: extdn/github-actions-m2/magento-phpstan@master - with: - composer_name: customgento/module-cli-tax-editor-m2 + uses: customgento/m2-github-actions/.github/workflows/phpstan.yml@main + with: + composer_name: customgento/module-cli-tax-editor-m2 + diff --git a/composer.json b/composer.json index 107f84d..eb7e544 100644 --- a/composer.json +++ b/composer.json @@ -12,7 +12,7 @@ "require": { "magento/framework": "~102.0||~103.0", "magento/module-tax": "~100.3||~100.4", - "php": "~7.3.0||~7.4.0||~8.1.0||~8.2.0", + "php": "~7.3.0||~7.4.0||~8.1.0||~8.2.0||~8.3.0", "symfony/console": "~4.1||~5.4" }, "require-dev": { From 93dfab0baa05189104226c8ffcd8fda8eae0f495 Mon Sep 17 00:00:00 2001 From: Rana Muhammad Irshad Date: Fri, 24 May 2024 14:59:57 +0200 Subject: [PATCH 2/4] Update symfony console version, DEV-569 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index eb7e544..9d21609 100644 --- a/composer.json +++ b/composer.json @@ -13,7 +13,7 @@ "magento/framework": "~102.0||~103.0", "magento/module-tax": "~100.3||~100.4", "php": "~7.3.0||~7.4.0||~8.1.0||~8.2.0||~8.3.0", - "symfony/console": "~4.1||~5.4" + "symfony/console": "~4.1||~5.4||~7.2" }, "require-dev": { "roave/security-advisories": "dev-latest" From 6c2ce504251ffc3c241cac8257aa53979e364358 Mon Sep 17 00:00:00 2001 From: Rana Muhammad Irshad Date: Fri, 24 May 2024 15:33:24 +0200 Subject: [PATCH 3/4] Update symfony, DEV-569 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 9d21609..ae31fdb 100644 --- a/composer.json +++ b/composer.json @@ -13,7 +13,7 @@ "magento/framework": "~102.0||~103.0", "magento/module-tax": "~100.3||~100.4", "php": "~7.3.0||~7.4.0||~8.1.0||~8.2.0||~8.3.0", - "symfony/console": "~4.1||~5.4||~7.2" + "symfony/console": "~4.1||~5.4||~6.4.0" }, "require-dev": { "roave/security-advisories": "dev-latest" From 6b2dd1b7bef2566df959dc7efc3adc202d988052 Mon Sep 17 00:00:00 2001 From: Rana Muhammad Irshad Date: Mon, 27 May 2024 09:24:29 +0200 Subject: [PATCH 4/4] Remove env, DEV-569 --- .github/workflows/integration.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index 2b60213..72b8d81 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -1,7 +1,6 @@ name: ExtDN M2 Integration Tests on: [ push, pull_request ] -env: - HYVA_GITLAB_TOKEN: ${{ secrets.HYVA_GITLAB_TOKEN }} + jobs: integration: uses: customgento/m2-github-actions/.github/workflows/integration.yml@main