| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 15503ff commit 3b077a6
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -2,7 +2,6 @@ | |||
| 2 | 2 | const { | |
| 3 | 3 | ArrayPrototypeForEach, | |
| 4 | 4 | SafeMap, | |
| 5 | - SafeWeakSet, | ||
| 6 | 5 | } = primordials; | |
| 7 | 6 | const { | |
| 8 | 7 | createHook, | |
@@ -23,7 +22,6 @@ const { | |||
| 23 | 22 | const { bigint: hrtime } = process.hrtime; | |
| 24 | 23 | ||
| 25 | 24 | const testResources = new SafeMap(); | |
| 26 | - const wasRootSetup = new SafeWeakSet(); | ||
| 27 | 25 | ||
| 28 | 26 | function createTestTree(options = kEmptyObject) { | |
| 29 | 27 | return setup(new Test({ __proto__: null, ...options, name: '<root>' })); | |
@@ -102,7 +100,7 @@ function collectCoverage(rootTest, coverage) { | |||
| 102 | 100 | } | |
| 103 | 101 | ||
| 104 | 102 | function setup(root) { | |
| 105 | - if (wasRootSetup.has(root)) { | ||
| 103 | + if (root.startTime !== null) { | ||
| 106 | 104 | return root; | |
| 107 | 105 | } | |
| 108 | 106 | ||
@@ -166,8 +164,6 @@ function setup(root) { | |||
| 166 | 164 | coverage: null, | |
| 167 | 165 | }; | |
| 168 | 166 | root.startTime = hrtime(); | |
| 169 | - | ||
| 170 | - wasRootSetup.add(root); | ||
| 171 | 167 | return root; | |
| 172 | 168 | } | |
| 173 | 169 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments