Skip to content

Commit

Permalink
Add tasks for running all the site installers (#662)
Browse files Browse the repository at this point in the history
  • Loading branch information
justafish committed Aug 20, 2024
1 parent e4f830c commit 02bc6a1
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 24 deletions.
35 changes: 11 additions & 24 deletions .github/workflows/TestFunctional.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@ jobs:
ddev config --web-environment="NIGHTWATCH_DRUPAL_URL_FIREFOX=https://drupal_firefox,NIGHTWATCH_DRUPAL_URL_CHROME=https://drupal_chrome"
ddev config --additional-hostnames="*.drainpipe"
- name: Run the site installer
run: |
ddev drush --yes site:install minimal
ddev drush config:export --yes
- name: Create Artifact
run: zip -r /tmp/drainpipe.zip ./

Expand Down Expand Up @@ -107,10 +112,7 @@ jobs:
- name: Install Drupal
run: |
ddev drush --yes site:install
ddev drush --uri=https://drupal_firefox --yes site:install
ddev drush --uri=https://drupal_chrome --yes site:install
ddev drush config:export --yes
ddev task test:siteinstall:all
- name: Run Functional Tests
run: ddev task test:functional
Expand Down Expand Up @@ -161,10 +163,7 @@ jobs:
- name: Install Drupal
run: |
ddev drush --yes site:install
ddev drush --uri=https://drupal_firefox --yes site:install
ddev drush --uri=https://drupal_chrome --yes site:install
ddev drush config:export --yes
ddev task test:siteinstall:all
- name: Run Functional Tests
run: ddev task test:functional
Expand Down Expand Up @@ -215,10 +214,7 @@ jobs:
- name: Install Drupal
run: |
ddev drush --yes site:install
ddev drush --uri=https://drupal_firefox --yes site:install
ddev drush --uri=https://drupal_chrome --yes site:install
ddev drush config:export --yes
ddev task test:siteinstall:all
- name: Run Functional Tests
run: ddev task test:functional
Expand Down Expand Up @@ -270,10 +266,7 @@ jobs:
- name: Install Drupal
run: |
ddev drush --yes site:install
ddev drush --uri=https://drupal_firefox --yes site:install
ddev drush --uri=https://drupal_chrome --yes site:install
ddev drush config:export --yes
ddev task test:siteinstall:all
- name: Run Functional Tests
run: ddev task test:functional
Expand Down Expand Up @@ -327,10 +320,7 @@ jobs:
- name: Install Drupal
run: |
ddev drush --yes site:install
ddev drush --uri=https://drupal_firefox --yes site:install
ddev drush --uri=https://drupal_chrome --yes site:install
ddev drush config:export --yes
ddev task test:siteinstall:all
- name: Run Functional Tests
run: ddev task test:functional
Expand Down Expand Up @@ -385,10 +375,7 @@ jobs:
- name: Install Drupal
run: |
ddev drush --yes site:install
ddev drush --uri=https://drupal_firefox --yes site:install
ddev drush --uri=https://drupal_chrome --yes site:install
ddev drush config:export --yes
ddev task test:siteinstall:all
- name: Run Functional Tests
run: ddev task test:functional
Expand Down
17 changes: 17 additions & 0 deletions tasks/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -280,6 +280,23 @@ tasks:
echo "ddev config --additional-hostnames=\"*.$DDEV_SITENAME\""
echo "ddev restart"
fi
siteinstall:default:
desc: "Runs the site installer for the default site"
cmds:
- ./vendor/bin/drush --yes site:install --existing-config
siteinstall:firefox:
desc: "Runs the site installer for the Firefox container"
cmds:
- ./vendor/bin/drush --uri=https://drupal_firefox --yes site:install --existing-config
siteinstall:chrome:
desc: "Runs the site installer for the Chrome container"
cmds:
- ./vendor/bin/drush --uri=https://drupal_chrome --yes site:install --existing-config
siteinstall:all:
desc: "Runs the site installer for the default site, Chrome, and Firefox container"
deps: [ siteinstall:default, siteinstall:firefox, siteinstall:chrome ]
cmds:
- echo "Default, Chrome, and Firefox installed"
nightwatch:siteinstall:firefox:
desc: "Runs the site installer for the Firefox container"
cmds:
Expand Down

0 comments on commit 02bc6a1

Please sign in to comment.