@@ -4,8 +4,8 @@ func foo(value: MyStruct) {
44
55// REQUIRES: shell
66
7- // RUN: DEPCHECK_INTERVAL=1
8- // RUN: SLEEP_TIME=2
7+ // RUN: DEPCHECK_INTERVAL=2
8+ // RUN: SLEEP_TIME=3
99
1010// RUN: %empty-directory(%t)
1111// RUN: %empty-directory(%t/VFS)
@@ -23,7 +23,14 @@ func foo(value: MyStruct) {
2323
2424// RUN: -shell -- echo "### Keep" == \
2525// RUN: -shell -- sleep ${SLEEP_TIME} == \
26- // RUN: -req=complete -pos=2:9 -pass-as-sourcetext -vfs-files=%t/VFS/Main.swift=@%s,%t/VFS/Library.swift=@%S/Inputs/checkdeps/MyProject_mod/Library.swift %t/VFS/Main.swift -- -target %target-triple %t/VFS/Main.swift %t/VFS/LibraryExt.swift %t/VFS/Library.swift \
26+ // RUN: -req=complete -pos=2:9 -pass-as-sourcetext -vfs-files=%t/VFS/Main.swift=@%s,%t/VFS/Library.swift=@%S/Inputs/checkdeps/MyProject_mod/Library.swift %t/VFS/Main.swift -- -target %target-triple %t/VFS/Main.swift %t/VFS/LibraryExt.swift %t/VFS/Library.swift == \
27+
28+ // RUN: -shell -- echo "### Rollback without sleep" == \
29+ // RUN: -req=complete -pos=2:9 -pass-as-sourcetext -vfs-files=%t/VFS/Main.swift=@%s,%t/VFS/Library.swift=@%S/Inputs/checkdeps/MyProject/Library.swift %t/VFS/Main.swift -- -target %target-triple %t/VFS/Main.swift %t/VFS/LibraryExt.swift %t/VFS/Library.swift == \
30+
31+ // RUN: -shell -- echo "### After sleep" == \
32+ // RUN: -shell -- sleep ${SLEEP_TIME} == \
33+ // RUN: -req=complete -pos=2:9 -pass-as-sourcetext -vfs-files=%t/VFS/Main.swift=@%s,%t/VFS/Library.swift=@%S/Inputs/checkdeps/MyProject/Library.swift %t/VFS/Main.swift -- -target %target-triple %t/VFS/Main.swift %t/VFS/LibraryExt.swift %t/VFS/Library.swift \
2734
2835// RUN: | %FileCheck %s
2936
@@ -50,3 +57,19 @@ func foo(value: MyStruct) {
5057// CHECK-DAG: key.description: "self"
5158// CHECK: ]
5259// CHECK: key.reusingastcontext: 1
60+
61+ // CHECK-LABEL: ### Rollback without sleep
62+ // CHECK: key.results: [
63+ // CHECK-DAG: key.description: "myStructMethod_mod()"
64+ // CHECK-DAG: key.description: "extensionMethod()"
65+ // CHECK-DAG: key.description: "self"
66+ // CHECK: ]
67+ // CHECK: key.reusingastcontext: 1
68+
69+ // CHECK-LABEL: ### After sleep
70+ // CHECK: key.results: [
71+ // CHECK-DAG: key.description: "myStructMethod()"
72+ // CHECK-DAG: key.description: "extensionMethod()"
73+ // CHECK-DAG: key.description: "self"
74+ // CHECK: ]
75+ // CHECK-NOT: key.reusingastcontext: 1
0 commit comments