Skip to content

Commit 03ef27c

Browse files
author
Stephen Belanger
committed
test: skip thenables test when using AsyncContextFrame
1 parent 22d1e52 commit 03ef27c

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

test/async-hooks/test-async-local-storage-thenable.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,22 @@
1+
// Flags: --expose-internals
12
'use strict';
23

34
const common = require('../common');
45

56
const assert = require('assert');
67
const { AsyncLocalStorage } = require('async_hooks');
78

9+
// TODO(qard): This is known to fail with ContinuationPreservedEmbedderData
10+
// as thenables are not yet supported in V8. A fix should hopefully land soon.
11+
//
12+
// See: https://chromium-review.googlesource.com/c/v8/v8/+/4674242
13+
const { internalBinding } = require('internal/test/binding');
14+
const { AsyncContextFrame } = internalBinding('async_context_frame');
15+
const hasAsyncContextFrame = typeof AsyncContextFrame === 'function';
16+
if (hasAsyncContextFrame) {
17+
return;
18+
}
19+
820
// This test verifies that async local storage works with thenables
921

1022
const store = new AsyncLocalStorage();

0 commit comments

Comments
 (0)