| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 0571d55 commit 18c9496
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -23,7 +23,6 @@ const { | |||
| 23 | 23 | SafeMap, | |
| 24 | 24 | SafePromiseAll, | |
| 25 | 25 | SafePromiseAllReturnVoid, | |
| 26 | - SafePromisePrototypeFinally, | ||
| 27 | 26 | SafePromiseRace, | |
| 28 | 27 | SafeSet, | |
| 29 | 28 | StringPrototypeStartsWith, | |
@@ -1259,27 +1258,20 @@ class Suite extends Test { | |||
| 1259 | 1258 | this.skipped = false; | |
| 1260 | 1259 | } | |
| 1261 | 1260 | ||
| 1261 | + this.buildSuite = this.createBuild(); | ||
| 1262 | + this.fn = noop; | ||
| 1263 | + } | ||
| 1264 | + | ||
| 1265 | + async createBuild() { | ||
| 1262 | 1266 | try { | |
| 1263 | 1267 | const { ctx, args } = this.getRunArgs(); | |
| 1264 | 1268 | const runArgs = [this.fn, ctx]; | |
| 1265 | 1269 | ArrayPrototypePushApply(runArgs, args); | |
| 1266 | - this.buildSuite = SafePromisePrototypeFinally( | ||
| 1267 | - PromisePrototypeThen( | ||
| 1268 | - PromiseResolve(ReflectApply(this.runInAsyncScope, this, runArgs)), | ||
| 1269 | - undefined, | ||
| 1270 | - (err) => { | ||
| 1271 | - this.fail(new ERR_TEST_FAILURE(err, kTestCodeFailure)); | ||
| 1272 | - }), | ||
| 1273 | - () => this.postBuild(), | ||
| 1274 | - ); | ||
| 1270 | + await ReflectApply(this.runInAsyncScope, this, runArgs); | ||
| 1275 | 1271 | } catch (err) { | |
| 1276 | 1272 | this.fail(new ERR_TEST_FAILURE(err, kTestCodeFailure)); | |
| 1277 | - this.postBuild(); | ||
| 1278 | 1273 | } | |
| 1279 | - this.fn = noop; | ||
| 1280 | - } | ||
| 1281 | 1274 | ||
| 1282 | - postBuild() { | ||
| 1283 | 1275 | this.buildPhaseFinished = true; | |
| 1284 | 1276 | } | |
| 1285 | 1277 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments