Skip to content

Commit bab68d0

Browse files
committed
t1
1 parent 2fbb84f commit bab68d0

File tree

2 files changed

+1
-121
lines changed

2 files changed

+1
-121
lines changed

.scaffold/tests/bats/ahoy.bats

Lines changed: 0 additions & 120 deletions
Original file line numberDiff line numberDiff line change
@@ -5,114 +5,6 @@ load _helper
55
export BATS_FIXTURE_EXPORT_CODEBASE_ENABLED=1
66

77
# bats file_tags=p1
8-
@test "ahoy build" {
9-
run ahoy build
10-
assert_success
11-
assert_output_contains "PROVISION COMPLETE"
12-
}
13-
14-
@test "ahoy assemble" {
15-
run ahoy assemble
16-
assert_success
17-
18-
assert_output_contains "ASSEMBLE COMPLETE"
19-
assert_dir_exists "${BUILD_DIR}/build/vendor"
20-
assert_file_exists "${BUILD_DIR}/build/composer.json"
21-
assert_file_exists "${BUILD_DIR}/build/composer.lock"
22-
assert_dir_exists "${BUILD_DIR}/node_modules"
23-
assert_output_contains "Would run build"
24-
}
25-
26-
@test "ahoy assemble - skip NPM build" {
27-
touch ".skip_npm_build"
28-
29-
run ahoy assemble
30-
assert_success
31-
32-
assert_output_contains "ASSEMBLE COMPLETE"
33-
assert_dir_exists "${BUILD_DIR}/build/vendor"
34-
assert_file_exists "${BUILD_DIR}/build/composer.json"
35-
assert_file_exists "${BUILD_DIR}/build/composer.lock"
36-
assert_dir_exists "${BUILD_DIR}/node_modules"
37-
assert_output_not_contains "Would run build"
38-
}
39-
40-
@test "ahoy start" {
41-
run ahoy start
42-
assert_failure
43-
assert_output_not_contains "ENVIRONMENT READY"
44-
45-
ahoy assemble
46-
run ahoy start
47-
assert_success
48-
49-
assert_output_contains "ENVIRONMENT READY"
50-
}
51-
52-
@test "ahoy stop" {
53-
run ahoy stop
54-
assert_success
55-
assert_output_contains "ENVIRONMENT STOPPED"
56-
57-
ahoy assemble
58-
ahoy start
59-
60-
run ahoy stop
61-
assert_success
62-
assert_output_contains "ENVIRONMENT STOPPED"
63-
}
64-
65-
@test "ahoy build - basic workflow" {
66-
run ahoy build
67-
assert_success
68-
assert_output_contains "PROVISION COMPLETE"
69-
70-
run ahoy drush status
71-
assert_success
72-
assert_output_contains "Database : Connected"
73-
assert_output_contains "Drupal bootstrap : Successful"
74-
75-
run ahoy login
76-
assert_success
77-
assert_output_contains "user/reset/1/"
78-
79-
ahoy lint
80-
assert_success
81-
82-
ahoy test
83-
assert_success
84-
assert_dir_exists "${BUILD_DIR}/build/web/sites/simpletest/browser_output"
85-
}
86-
87-
@test "ahoy lint, lint-fix" {
88-
ahoy assemble
89-
assert_success
90-
91-
ahoy lint
92-
assert_success
93-
94-
# shellcheck disable=SC2016
95-
echo '$a=123;echo $a;' >>your_extension.module
96-
run ahoy lint
97-
assert_failure
98-
99-
run ahoy lint-fix
100-
run ahoy lint
101-
assert_success
102-
}
103-
104-
@test "ahoy test unit failure" {
105-
run ahoy assemble
106-
assert_success
107-
108-
run ahoy test-unit
109-
assert_success
110-
111-
sed -i -e "s/assertEquals/assertNotEquals/g" "${BUILD_DIR}/tests/src/Unit/YourExtensionServiceUnitTest.php"
112-
run ahoy test-unit
113-
assert_failure
114-
}
115-
1168
@test "ahoy test functional failure" {
1179
run ahoy build
11810
assert_success
@@ -127,15 +19,3 @@ export BATS_FIXTURE_EXPORT_CODEBASE_ENABLED=1
12719
assert_failure
12820
assert_dir_not_exists "${BUILD_DIR}/build/web/sites/simpletest/browser_output"
12921
}
130-
131-
@test "ahoy test kernel failure" {
132-
run ahoy build
133-
assert_success
134-
135-
run ahoy test-kernel
136-
assert_success
137-
138-
sed -i -e "s/assertEquals/assertNotEquals/g" "${BUILD_DIR}/tests/src/Kernel/YourExtensionServiceKernelTest.php"
139-
run ahoy test-kernel
140-
assert_failure
141-
}

phpunit.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
initialize the hardcoded output directory.
3434
@see https://www.drupal.org/node/2992069
3535
-->
36-
<env name="BROWSERTEST_OUTPUT_DIRECTORY" value=""/>
36+
<env name="BROWSERTEST_OUTPUT_DIRECTORY" value=".logs"/>
3737
<!-- By default, browser tests will output links that use the base URL set
3838
in SIMPLETEST_BASE_URL. However, if your SIMPLETEST_BASE_URL is an internal
3939
path (such as may be the case in a virtual or Container-based environment),

0 commit comments

Comments
 (0)