Skip to content
This repository has been archived by the owner on Oct 15, 2020. It is now read-only.

Commit

Permalink
test,build: implement no-ops for Promise::Resolver methods, mark test…
Browse files Browse the repository at this point in the history
…s as flaky
  • Loading branch information
jackhorton authored and MSLaguana committed Sep 27, 2017
1 parent 08a2c07 commit 743f634
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
17 changes: 15 additions & 2 deletions deps/chakrashim/src/v8resolver.cc
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,19 @@
namespace v8 {
using Resolver = Promise::Resolver;
// CHAKRA-TODO: Unimplemented completely
MaybeLocal<Resolver> Resolver::New(
Local<Context> context) {
MaybeLocal<Resolver> Resolver::New(Local<Context> context) {
return Local<Resolver>();
}

Local<Resolver> Resolver::New(Isolate* isolate) {
return New(isolate->GetCurrentContext()).ToLocalChecked();
}

Local<Promise> Resolver::GetPromise() {
CHAKRA_ASSERT(false);
return Local<Promise>();
}

Resolver* Resolver::Cast(Value* obj) {
return static_cast<Resolver*>(obj);
}
Expand All @@ -37,6 +45,11 @@ namespace v8 {
return Just(false);
}

void Resolver::Resolve(Local<Value> value) {
Local<Context> context;
Resolve(context, value);
}

Maybe<bool> Resolver::Reject(Local<Context> context, Local<Value> value) {
return Just(false);
}
Expand Down
2 changes: 2 additions & 0 deletions test/addons/addon.status
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,5 @@ prefix addons
[$jsEngine==chakracore]
async-hooks-promise/test : PASS,FLAKY
new-target/test : PASS,FLAKY
callback-scope/test : PASS,FLAKY
callback-scope/test-resolve-async : PASS,FLAKY

0 comments on commit 743f634

Please sign in to comment.