Skip to content

Commit

Permalink
no theme required (#26)
Browse files Browse the repository at this point in the history
  • Loading branch information
janette committed Apr 5, 2023
1 parent 81e2fec commit 77f24cb
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 21 deletions.
13 changes: 4 additions & 9 deletions commands/web/dkan-frontend-install
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,10 @@ fi
FRONTEND_VCS_URL='https://github.com/GetDKAN/data-catalog-app/'
FRONTEND_VCS_REF='no-node-sass'

if [ $FRONTEND_THEME_INSTALL = 1 ]; then
echo " * Installing default frontend theme."
composer require getdkan/$FRONTEND_THEME
drush theme:enable $FRONTEND_THEME
drush config-set system.theme default $FRONTEND_THEME -y
drush pm-enable dkan_js_frontend -y
else
echo " * Not installing default frontend theme."
fi

drush pm-enable dkan_js_frontend -y
drush config-set system.site page.front '/home' -y
drush cr

echo " ** Gathering frontend application: $FRONTEND_VCS_REF from $FRONTEND_VCS_URL"

Expand Down
12 changes: 1 addition & 11 deletions tests/dkan-frontend-install.bats
Original file line number Diff line number Diff line change
Expand Up @@ -26,18 +26,8 @@ teardown() {
[ "${TESTDIR}" != "" ] && rm -rf ${TESTDIR}
}

@test "dkan-frontend-install" {
run ddev dkan-frontend-install
assert_output --partial "Installing default frontend theme"
refute_output --partial "Not installing default frontend theme"
assert_output --partial "Gathering frontend application"
assert_success
}

@test "dkan-frontend-install no default theme" {
run ddev dkan-frontend-install --theme 0
refute_output --partial "Installing default frontend theme"
assert_output --partial "Not installing default frontend theme"
run ddev dkan-frontend-install
assert_output --partial "Gathering frontend application"
assert_success
}
1 change: 0 additions & 1 deletion tests/frontend.bats
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ teardown() {
set -eu -o pipefail

run ddev dkan-frontend-install
refute_output --partial "Not installing default frontend theme"
assert_output --partial 'Gathering frontend application:'
assert_output --partial "Frontend install complete."
assert_success
Expand Down

0 comments on commit 77f24cb

Please sign in to comment.