-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathtests
More file actions
executable file
·82 lines (71 loc) · 2.3 KB
/
tests
File metadata and controls
executable file
·82 lines (71 loc) · 2.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#!/usr/bin/env bash
#ddev-generated
#annertech-ddev
## Description: Informs you about available test suites in current project
## Usage: tests
## Example: ddev tests
set -euo pipefail
underline=$(tput smul)
nounderline=$(tput rmul)
bold=$(tput bold)
normal=$(tput sgr0)
echo
# ---------------------------------------------------------------------------
# Backstop
# ---------------------------------------------------------------------------
if [ -f "${DDEV_APPROOT}/tests/backstop/backstop.json" ]; then
backstop_addon="$(
ddev check-addon ddev/ddev-backstopjs "Backstop tests"
)"
if [ "$backstop_addon" = "installed" ]; then
echo "${bold}Backstop:${normal}"
echo " ddev backstop reference"
echo " ddev backstop test"
echo " ddev backstop-results"
echo
fi
fi
# ---------------------------------------------------------------------------
# Behat
# ---------------------------------------------------------------------------
if [ -f "${DDEV_APPROOT}/tests/behat/behat.yml" ]; then
echo "${bold}Behat:${normal}"
echo " ddev ssh"
echo " cd tests/behat"
echo " bin/behat"
echo
fi
# ---------------------------------------------------------------------------
# Bruno
# ---------------------------------------------------------------------------
if [ -f "${DDEV_APPROOT}/tests/bruno/bruno/bruno.json" ]; then
echo "${bold}Bruno:${normal}"
echo " Runs outside DDEV, see https://www.usebruno.com/"
echo
fi
# ---------------------------------------------------------------------------
# Cypress
# ---------------------------------------------------------------------------
if [ -f "${DDEV_APPROOT}/cypress.config.js" ]; then
cypress_addon="$(
ddev check-addon ddev/ddev-cypress "Cypress tests"
)"
if [ "$cypress_addon" = "installed" ]; then
echo "${bold}Cypress:${normal}"
echo " ddev cypress-run"
echo " ddev cypress-run --headed"
echo " ddev cypress-open"
echo
echo "If getting X related errors run xhost ${bold}first${normal}!"
echo " xhost +local:"
echo
fi
fi
# ---------------------------------------------------------------------------
# PHPUnit
# ---------------------------------------------------------------------------
if [ -f "${DDEV_APPROOT}/vendor/bin/phpunit" ]; then
echo "${bold}PHPUnit:${normal}"
echo " ddev phpunit"
echo
fi