From a9fa3b2f83a29bdf3903c5589180cd4d1503c7bf Mon Sep 17 00:00:00 2001 From: sayan goswami Date: Thu, 16 Nov 2023 15:24:18 +0530 Subject: [PATCH 1/9] testing --- src/Domain/Fixture/FixtureCreator.php | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/Domain/Fixture/FixtureCreator.php b/src/Domain/Fixture/FixtureCreator.php index 1c4ef927d..589bec707 100644 --- a/src/Domain/Fixture/FixtureCreator.php +++ b/src/Domain/Fixture/FixtureCreator.php @@ -237,6 +237,7 @@ public function create(FixtureOptions $options): void { $this->ensureDrupalSettings(); $this->installSite(); $this->setUpFilesDirectories(); + $this->runACMSCommands(); $this->customizeFixture(); $this->createAndCheckoutBackupTag(); $this->displaySecurityVulnerabilityAdvisories(); @@ -938,6 +939,16 @@ private function setUpFilesDirectories(): void { ], $directories)); } + /** + * @return void + */ + public function runACMSCommands(): void { + $this->output->section('Run ACMS Site Build'); + $this->processRunner->runFixtureVendorBin(['acms','acms:build']); + $this->output->section('Run ACMS Site Install'); + $this->processRunner->runFixtureVendorBin(['acms','acms:install']); + } + /** * Customize the fixture. */ From f61d2b9b681cd639e1d20f0cfe134a6062dfe12d Mon Sep 17 00:00:00 2001 From: sayan goswami Date: Thu, 16 Nov 2023 15:28:24 +0530 Subject: [PATCH 2/9] Update FixtureCreator.php --- src/Domain/Fixture/FixtureCreator.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Domain/Fixture/FixtureCreator.php b/src/Domain/Fixture/FixtureCreator.php index 589bec707..4cfaa0fea 100644 --- a/src/Domain/Fixture/FixtureCreator.php +++ b/src/Domain/Fixture/FixtureCreator.php @@ -237,7 +237,7 @@ public function create(FixtureOptions $options): void { $this->ensureDrupalSettings(); $this->installSite(); $this->setUpFilesDirectories(); - $this->runACMSCommands(); + $this->runAcmsCommands(); $this->customizeFixture(); $this->createAndCheckoutBackupTag(); $this->displaySecurityVulnerabilityAdvisories(); @@ -940,13 +940,13 @@ private function setUpFilesDirectories(): void { } /** - * @return void + * Runs ACMS commands. */ - public function runACMSCommands(): void { + public function runAcmsCommands(): void { $this->output->section('Run ACMS Site Build'); - $this->processRunner->runFixtureVendorBin(['acms','acms:build']); + $this->processRunner->runFixtureVendorBin(['acms', 'acms:build']); $this->output->section('Run ACMS Site Install'); - $this->processRunner->runFixtureVendorBin(['acms','acms:install']); + $this->processRunner->runFixtureVendorBin(['acms', 'acms:install']); } /** From d4d7989291c198689239f50e9f8b2759a3012c36 Mon Sep 17 00:00:00 2001 From: sayan goswami Date: Thu, 16 Nov 2023 15:32:11 +0530 Subject: [PATCH 3/9] commenting --- .github/workflows/orca.yml | 60 +++++++++++++++++++------------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/.github/workflows/orca.yml b/.github/workflows/orca.yml index 27369a562..49f3b9742 100644 --- a/.github/workflows/orca.yml +++ b/.github/workflows/orca.yml @@ -39,45 +39,45 @@ jobs: strategy: matrix: orca-job: - - STATIC_CODE_ANALYSIS - - INTEGRATED_TEST_ON_OLDEST_SUPPORTED - - INTEGRATED_TEST_ON_PREVIOUS_MINOR - - INTEGRATED_TEST_ON_LATEST_LTS +# - STATIC_CODE_ANALYSIS +# - INTEGRATED_TEST_ON_OLDEST_SUPPORTED +# - INTEGRATED_TEST_ON_PREVIOUS_MINOR +# - INTEGRATED_TEST_ON_LATEST_LTS # - INTEGRATED_UPGRADE_TEST_FROM_PREVIOUS_MINOR - INTEGRATED_TEST_ON_CURRENT # - INTEGRATED_UPGRADE_TEST_TO_NEXT_MINOR - - ISOLATED_TEST_ON_CURRENT_DEV - - INTEGRATED_TEST_ON_CURRENT_DEV - - STRICT_DEPRECATED_CODE_SCAN - - ISOLATED_TEST_ON_NEXT_MINOR - - INTEGRATED_TEST_ON_NEXT_MINOR +# - ISOLATED_TEST_ON_CURRENT_DEV +# - INTEGRATED_TEST_ON_CURRENT_DEV +# - STRICT_DEPRECATED_CODE_SCAN +# - ISOLATED_TEST_ON_NEXT_MINOR +# - INTEGRATED_TEST_ON_NEXT_MINOR # - ISOLATED_UPGRADE_TEST_TO_NEXT_MAJOR_BETA_OR_LATER # - ISOLATED_UPGRADE_TEST_TO_NEXT_MAJOR_DEV - - DEPRECATED_CODE_SCAN_W_CONTRIB - - INTEGRATED_TEST_ON_NEXT_MINOR_DEV - - ISOLATED_TEST_ON_NEXT_MINOR_DEV +# - DEPRECATED_CODE_SCAN_W_CONTRIB +# - INTEGRATED_TEST_ON_NEXT_MINOR_DEV +# - ISOLATED_TEST_ON_NEXT_MINOR_DEV # - INTEGRATED_UPGRADE_TEST_TO_NEXT_MINOR_DEV - - LOOSE_DEPRECATED_CODE_SCAN - - INTEGRATED_TEST_ON_NEXT_MAJOR_LATEST_MINOR_BETA_OR_LATER - - ISOLATED_TEST_ON_NEXT_MAJOR_LATEST_MINOR_DEV - - INTEGRATED_TEST_ON_NEXT_MAJOR_LATEST_MINOR_DEV +# - LOOSE_DEPRECATED_CODE_SCAN +# - INTEGRATED_TEST_ON_NEXT_MAJOR_LATEST_MINOR_BETA_OR_LATER +# - ISOLATED_TEST_ON_NEXT_MAJOR_LATEST_MINOR_DEV +# - INTEGRATED_TEST_ON_NEXT_MAJOR_LATEST_MINOR_DEV php-version: [ "8.1" ] orca-enable-nightwatch: [ "FALSE" ] orca-coverage-enable: [ "FALSE" ] - include: - # Testing Drupal 10 in php 8.1 with nightwatch and coverage. - - orca-job: ISOLATED_TEST_ON_CURRENT - php-version: "8.1" - orca-enable-nightwatch: "TRUE" - orca-coverage-enable: "TRUE" - - # Testing Drupal 10 in php 8.2. - - orca-job: ISOLATED_TEST_ON_CURRENT - php-version: "8.2" - - # Testing latest Drupal 9 in php 8.2. - - orca-job: INTEGRATED_TEST_ON_LATEST_LTS - php-version: "8.2" +# include: +# # Testing Drupal 10 in php 8.1 with nightwatch and coverage. +# - orca-job: ISOLATED_TEST_ON_CURRENT +# php-version: "8.1" +# orca-enable-nightwatch: "TRUE" +# orca-coverage-enable: "TRUE" +# +# # Testing Drupal 10 in php 8.2. +# - orca-job: ISOLATED_TEST_ON_CURRENT +# php-version: "8.2" +# +# # Testing latest Drupal 9 in php 8.2. +# - orca-job: INTEGRATED_TEST_ON_LATEST_LTS +# php-version: "8.2" steps: From c90469d50bb89fbbe1862678e4d28be23f1323ed Mon Sep 17 00:00:00 2001 From: sayan goswami Date: Thu, 16 Nov 2023 17:58:38 +0530 Subject: [PATCH 4/9] no-interaction --- src/Domain/Fixture/FixtureCreator.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Domain/Fixture/FixtureCreator.php b/src/Domain/Fixture/FixtureCreator.php index 4cfaa0fea..b23faddd3 100644 --- a/src/Domain/Fixture/FixtureCreator.php +++ b/src/Domain/Fixture/FixtureCreator.php @@ -944,9 +944,9 @@ private function setUpFilesDirectories(): void { */ public function runAcmsCommands(): void { $this->output->section('Run ACMS Site Build'); - $this->processRunner->runFixtureVendorBin(['acms', 'acms:build']); + $this->processRunner->runFixtureVendorBin(['acms', 'acms:build', '--no-interaction']); $this->output->section('Run ACMS Site Install'); - $this->processRunner->runFixtureVendorBin(['acms', 'acms:install']); + $this->processRunner->runFixtureVendorBin(['acms', 'acms:install', '--no-interaction']); } /** From 8d250728fa782bd019965b0e0412ad1a133ab8a2 Mon Sep 17 00:00:00 2001 From: sayan goswami Date: Thu, 16 Nov 2023 18:27:05 +0530 Subject: [PATCH 5/9] Update FixtureCreator.php --- src/Domain/Fixture/FixtureCreator.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Domain/Fixture/FixtureCreator.php b/src/Domain/Fixture/FixtureCreator.php index b23faddd3..ced2303dc 100644 --- a/src/Domain/Fixture/FixtureCreator.php +++ b/src/Domain/Fixture/FixtureCreator.php @@ -943,6 +943,9 @@ private function setUpFilesDirectories(): void { * Runs ACMS commands. */ public function runAcmsCommands(): void { + if($this->fixtureInspector->getInstalledPackageVersionPretty('acquia/acquia_cms') === '~'){ + return; + } $this->output->section('Run ACMS Site Build'); $this->processRunner->runFixtureVendorBin(['acms', 'acms:build', '--no-interaction']); $this->output->section('Run ACMS Site Install'); From 37279352515eb4d46cb87cc8fbd98cd133d8a2df Mon Sep 17 00:00:00 2001 From: sayan goswami Date: Thu, 16 Nov 2023 18:56:53 +0530 Subject: [PATCH 6/9] add env var --- config/services.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/config/services.yml b/config/services.yml index 595203ec7..d7215be9e 100644 --- a/config/services.yml +++ b/config/services.yml @@ -14,6 +14,8 @@ parameters: env(ORCA_PHPCS_STANDARD): "AcquiaDrupalTransitional" env(ORCA_TELEMETRY_ENABLE): "false" env(ORCA_IS_ALLOWED_FAILURE): "%env(ORCA_IS_ALLOWED_FAILURE)%" + env(SITESTUDIO_API_KEY): "key-cohesion-baseline" + env(SITESTUDIO_ORG_KEY): "test-cohesion-baseline" services: From fb9c8b9656e2349867e85299981c1e83f7f4da94 Mon Sep 17 00:00:00 2001 From: sayan goswami Date: Thu, 16 Nov 2023 19:47:13 +0530 Subject: [PATCH 7/9] updates --- bin/ci/_includes.sh | 2 ++ config/services.yml | 2 -- src/Domain/Fixture/FixtureCreator.php | 2 +- src/Enum/EnvVarEnum.php | 8 ++++++++ 4 files changed, 11 insertions(+), 3 deletions(-) diff --git a/bin/ci/_includes.sh b/bin/ci/_includes.sh index 245a9751d..9357c8891 100755 --- a/bin/ci/_includes.sh +++ b/bin/ci/_includes.sh @@ -73,6 +73,8 @@ export DRUPAL_TEST_DB_URL="sqlite://localhost/sites/default/files/db.sqlite" export DRUPAL_TEST_WEBDRIVER_CHROME_ARGS="--disable-gpu --headless --no-sandbox" export DRUPAL_TEST_WEBDRIVER_HOSTNAME="localhost" export DRUPAL_TEST_WEBDRIVER_PORT="4444" +export SITESTUDIO_API_KEY="key-cohesion-baseline" +export SITESTUDIO_ORG_KEY="test-cohesion-baseline" if [[ ! "$ORCA_TEMP_DIR" ]]; then # GitHub Actions. diff --git a/config/services.yml b/config/services.yml index d7215be9e..595203ec7 100644 --- a/config/services.yml +++ b/config/services.yml @@ -14,8 +14,6 @@ parameters: env(ORCA_PHPCS_STANDARD): "AcquiaDrupalTransitional" env(ORCA_TELEMETRY_ENABLE): "false" env(ORCA_IS_ALLOWED_FAILURE): "%env(ORCA_IS_ALLOWED_FAILURE)%" - env(SITESTUDIO_API_KEY): "key-cohesion-baseline" - env(SITESTUDIO_ORG_KEY): "test-cohesion-baseline" services: diff --git a/src/Domain/Fixture/FixtureCreator.php b/src/Domain/Fixture/FixtureCreator.php index ced2303dc..0467226bd 100644 --- a/src/Domain/Fixture/FixtureCreator.php +++ b/src/Domain/Fixture/FixtureCreator.php @@ -943,7 +943,7 @@ private function setUpFilesDirectories(): void { * Runs ACMS commands. */ public function runAcmsCommands(): void { - if($this->fixtureInspector->getInstalledPackageVersionPretty('acquia/acquia_cms') === '~'){ + if ($this->fixtureInspector->getInstalledPackageVersionPretty('acquia/acquia_cms') === '~') { return; } $this->output->section('Run ACMS Site Build'); diff --git a/src/Enum/EnvVarEnum.php b/src/Enum/EnvVarEnum.php index ba2698d6f..610bbf5c0 100644 --- a/src/Enum/EnvVarEnum.php +++ b/src/Enum/EnvVarEnum.php @@ -33,6 +33,8 @@ * @method static EnvVarEnum DRUPAL_TEST_WEBDRIVER_CHROME_ARGS() * @method static EnvVarEnum DRUPAL_TEST_WEBDRIVER_HOSTNAME() * @method static EnvVarEnum DRUPAL_TEST_WEBDRIVER_PORT() + * @method static EnvVarEnum SITESTUDIO_API_KEY() + * @method static EnvVarEnum SITESTUDIO_ORG_KEY() */ class EnvVarEnum extends Enum { @@ -93,6 +95,10 @@ class EnvVarEnum extends Enum { public const DRUPAL_TEST_WEBDRIVER_HOSTNAME = 'DRUPAL_TEST_WEBDRIVER_HOSTNAME'; public const DRUPAL_TEST_WEBDRIVER_PORT = 'DRUPAL_TEST_WEBDRIVER_PORT'; + public const SITESTUDIO_API_KEY = 'SITESTUDIO_API_KEY'; + public const SITESTUDIO_ORG_KEY = 'SITESTUDIO_ORG_KEY'; + + /** * Descriptions for the environment variables. @@ -131,6 +137,8 @@ public static function descriptions(): array { self::DRUPAL_TEST_WEBDRIVER_CHROME_ARGS => 'The Chrome WebDriver arguments (Read-only)', self::DRUPAL_TEST_WEBDRIVER_HOSTNAME => 'The WebDriver hostname (Read-only)', self::DRUPAL_TEST_WEBDRIVER_PORT => 'The WebDriver port (Read-only)', + self::SITESTUDIO_API_KEY => 'The Site Studio API Key', + self::SITESTUDIO_ORG_KEY => 'The Site Studio ORG Key', ]; } From 5c435a9314286657eaf82888882f2c011a7f02e2 Mon Sep 17 00:00:00 2001 From: sayan goswami Date: Tue, 28 Nov 2023 14:17:26 +0530 Subject: [PATCH 8/9] Re-order ACMS --- src/Domain/Fixture/FixtureCreator.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Domain/Fixture/FixtureCreator.php b/src/Domain/Fixture/FixtureCreator.php index 0467226bd..78cfed85c 100644 --- a/src/Domain/Fixture/FixtureCreator.php +++ b/src/Domain/Fixture/FixtureCreator.php @@ -230,6 +230,7 @@ public function create(FixtureOptions $options): void { $this->removeComposerConfigPlatform(); $this->replaceCoreRecommendedWithCore(); $this->fixDefaultDependencies(); + $this->runAcmsCommands(); $this->addAllowedComposerPlugins(); $this->addCompanyPackages(); $this->composer->updateLockFile(); @@ -237,7 +238,6 @@ public function create(FixtureOptions $options): void { $this->ensureDrupalSettings(); $this->installSite(); $this->setUpFilesDirectories(); - $this->runAcmsCommands(); $this->customizeFixture(); $this->createAndCheckoutBackupTag(); $this->displaySecurityVulnerabilityAdvisories(); From 82f144da04be5d024a7d65cbc1f1712b2e297cdb Mon Sep 17 00:00:00 2001 From: Raksha Bharuka Date: Fri, 11 Oct 2024 13:10:44 +0530 Subject: [PATCH 9/9] Update orca.yml --- .github/workflows/orca.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/orca.yml b/.github/workflows/orca.yml index 49f3b9742..c1f763491 100644 --- a/.github/workflows/orca.yml +++ b/.github/workflows/orca.yml @@ -158,3 +158,4 @@ jobs: jobs: ${{ toJSON(needs) }} - name: All checks successful run: echo "🎉" +