-
Notifications
You must be signed in to change notification settings - Fork 1.7k
/
composing-missing-workspace-config-deps.t
44 lines (38 loc) · 2.94 KB
/
composing-missing-workspace-config-deps.t
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
Setup
$ . ${TESTDIR}/../../../helpers/setup.sh
$ . ${TESTDIR}/../_helpers/setup_monorepo.sh $(pwd) composable_config
# The missing-workspace-config-task-with-deps configures dependsOn in the root turbo.json.
# The workspace does not have a turbo.json config. This test checks that both regular dependencies
# and Topological dependencies are retained from the root config.
# 1. First run, assert that dependet tasks run `dependsOn`
$ ${TURBO} run missing-workspace-config-task-with-deps --filter=missing-workspace-config > tmp.log
# Validate in pieces. `omit-key` task has two dependsOn values, and those tasks
# can run in non-deterministic order. So we need to validate the logs in the pieces.
$ cat tmp.log | grep "in scope" -A 2
\xe2\x80\xa2 Packages in scope: missing-workspace-config (esc)
\xe2\x80\xa2 Running missing-workspace-config-task-with-deps in 1 packages (esc)
\xe2\x80\xa2 Remote caching disabled (esc)
$ cat tmp.log | grep "missing-workspace-config:missing-workspace-config-task-with-deps"
missing-workspace-config:missing-workspace-config-task-with-deps: cache miss, executing 3834b61108827b4d
missing-workspace-config:missing-workspace-config-task-with-deps:
missing-workspace-config:missing-workspace-config-task-with-deps: > missing-workspace-config-task-with-deps
missing-workspace-config:missing-workspace-config-task-with-deps: > echo "running missing-workspace-config-task-with-deps" > out/foo.min.txt
missing-workspace-config:missing-workspace-config-task-with-deps:
$ cat tmp.log | grep "missing-workspace-config:missing-workspace-config-underlying-task"
missing-workspace-config:missing-workspace-config-underlying-task: cache miss, executing 90a40cdc23446a61
missing-workspace-config:missing-workspace-config-underlying-task:
missing-workspace-config:missing-workspace-config-underlying-task: > missing-workspace-config-underlying-task
missing-workspace-config:missing-workspace-config-underlying-task: > echo "running missing-workspace-config-underlying-task"
missing-workspace-config:missing-workspace-config-underlying-task:
missing-workspace-config:missing-workspace-config-underlying-task: running missing-workspace-config-underlying-task
$ cat tmp.log | grep "blank-pkg:missing-workspace-config-underlying-topo-task"
blank-pkg:missing-workspace-config-underlying-topo-task: cache miss, executing e8425e7d05ed24f2
blank-pkg:missing-workspace-config-underlying-topo-task:
blank-pkg:missing-workspace-config-underlying-topo-task: > missing-workspace-config-underlying-topo-task
blank-pkg:missing-workspace-config-underlying-topo-task: > echo "missing-workspace-config-underlying-topo-task from blank-pkg"
blank-pkg:missing-workspace-config-underlying-topo-task:
blank-pkg:missing-workspace-config-underlying-topo-task: missing-workspace-config-underlying-topo-task from blank-pkg
$ cat tmp.log | grep "Tasks:" -A 2
Tasks: 3 successful, 3 total
Cached: 0 cached, 3 total
Time:\s*[\.0-9]+m?s (re)