Skip to content

Commit

Permalink
tests: add gpp, devcontainer cli and python3 install tests
Browse files Browse the repository at this point in the history
  • Loading branch information
airscripts authored and Francesco Sardone committed Dec 26, 2022
1 parent 2260def commit 8c396ec
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 2 deletions.
18 changes: 18 additions & 0 deletions tests/install.bats
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,18 @@ setup() {
refute_output --partial "ERROR"
}

@test "Install gpp" {
run ./scripts/install/gpp.sh
assert_output --partial "$INSTALL_GPP"
refute_output --partial "ERROR"
}

@test "Install python3" {
run ./scripts/install/python3.sh
assert_output --partial "$INSTALL_PYTHON3"
refute_output --partial "ERROR"
}

@test "Install npm" {
run ./scripts/install/npm.sh
assert_output --partial "$INSTALL_NPM"
Expand All @@ -50,6 +62,12 @@ setup() {
refute_output --partial "ERR!"
}

@test "Install devcontainer CLI" {
run ./scripts/install/devcontainer-cli.sh
assert_output --partial "$INSTALL_DEVCONTAINER_CLI"
refute_output --partial "ERR!"
}

@test "Install Bats" {
run ./scripts/install/bats.sh
assert_output --partial "$INSTALL_BATS"
Expand Down
8 changes: 6 additions & 2 deletions tests/mocks.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,18 @@
#!/bin/bash
readonly INSTALL_NPM="npm installed successfully."
readonly INSTALL_GIT="Git installed successfully."
readonly INSTALL_GPP="gpp installed successfully."
readonly INSTALL_BATS="Bats installed successfully."
readonly INSTALL_HUGO="Hugo installed successfully."
readonly INSTALL_MAKE="Make installed successfully."
readonly INSTALL_CURL="curl installed successfully."
readonly INSTALL_BASH="Bash installed successfully."
readonly SKIP_INSTALL_GIT="Git installation has been skipped."
readonly INSTALL_PYTHON3="python3 installed successfully."
readonly INSTALL_DOCKER_CLI="Docker CLI installed successfully."
readonly INSTALL_NETLIFY_CLI="Netlify CLI installed successfully."
readonly ADD_GIT_SUBMODULE_SKIPPED="Git submodule update skipped."
readonly INSTALL_CIRCLECI_CLI="CircleCI CLI installed successfully."
readonly INSTALL_DEVCONTAINER_CLI="devcontainer CLI installed successfully."

readonly SKIP_INSTALL_GIT="Git installation has been skipped."
readonly ADD_GIT_SUBMODULE_SKIPPED="Git submodule update skipped."
readonly ADD_GIT_SUBMODULE_EXECUTED="Git submodule update executed."

0 comments on commit 8c396ec

Please sign in to comment.