-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtest.mk
More file actions
96 lines (78 loc) · 2.88 KB
/
test.mk
File metadata and controls
96 lines (78 loc) · 2.88 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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
# WARNING: Please DO NOT edit this file! It is maintained in the Repository Template (https://github.com/nhs-england-tools/repository-template). Raise a PR instead.
# The test types listed here are both those which might run both locally and in CI, or
# in one but not the other. All of the test types listed at
# https://github.com/NHSDigital/software-engineering-quality-framework/blob/main/quality-checks.md
# should be represented here with the exception of:
# - dependency scanning, which we expect to be applied at the repository level
# - secret scanning, which we expect to be a pre-commit hook
# - code review, which is outside the scope of automated testing for the moment
test-unit: # Run your unit tests from scripts/test/unit @Testing
make _test name="unit"
test-lint: # Lint your code from scripts/test/lint @Testing
make _test name="lint"
test-features: # Run feature (Behave) tests @Testing
make _test name="features"
test-coverage: # Evaluate code coverage from scripts/test/coverage @Testing
make _test name="coverage"
test-accessibility: # Run your accessibility tests from scripts/test/accessibility @Testing
make _test name="accessibility"
test-contract: # Run your contract tests from scripts/test/contract @Testing
make _test name="contract"
test-integration: # Run your integration tests from scripts/test/integration @Testing
make _test name="integration"
test-load: # Run all your load tests @Testing
make \
test-capacity \
test-soak \
test-response-time
# You may wish to add more here, depending on your app
test-capacity: # Test what load level your app fails at from scripts/test/capacity @Testing
make _test name="capacity"
test-soak: # Test that resources don't get exhausted over time from scripts/test/soak @Testing
make _test name="soak"
test-response-time: # Test your API response times from scripts/test/response-time @Testing
make _test name="response-time"
test-security: # Run your security tests from scripts/test/security @Testing
make _test name="security"
test-ui: # Run your UI tests from scripts/test/ui @Testing
make _test name="ui"
test-ui-performance: # Run UI render tests from scripts/test/ui-performance @Testing
make _test name="ui-performance"
test: # Run all the test tasks @Testing
make \
test-unit \
test-lint \
test-features \
test-coverage \
test-contract \
test-security \
test-ui \
test-ui-performance \
test-integration \
test-accessibility \
test-load
_test:
set -e; \
script="./scripts/tests/${name}.sh"; \
if [ -e "$${script}" ]; then \
exec $${script}; \
else \
echo "make test-${name} not implemented: $${script} not found" >&2; \
fi
${VERBOSE}.SILENT: \
_test \
test \
test-accessibility \
test-capacity \
test-contract \
test-coverage \
test-soak \
test-integration \
test-lint \
test-load \
test-response-time \
test-security \
test-ui \
test-ui-performance \
test-unit \
test-features \