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

Commit a5e48bf

Browse files
committed
chakrashim,test: fixes from merge
* Add missing tracing API * Skip new flaky test * Fix lint issues
1 parent f8f6b8e commit a5e48bf

File tree

5 files changed

+25
-10
lines changed

5 files changed

+25
-10
lines changed

deps/chakrashim/include/libplatform/v8-tracing.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,8 @@ class TraceWriter {
9898
virtual void Flush() = 0;
9999

100100
static TraceWriter* CreateJSONTraceWriter(std::ostream& stream);
101+
static TraceWriter* CreateJSONTraceWriter(std::ostream& stream,
102+
const std::string& tag);
101103

102104
private:
103105
// Disallow copy and assign

deps/chakrashim/include/v8-inspector.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
#include <cctype>
1010

1111
#include <memory>
12+
#include <vector>
1213

1314
#include "v8.h" // NOLINT(build/include)
1415

deps/chakrashim/lib/chakra_shim.js

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -673,14 +673,16 @@
673673
return ownPropertyNames;
674674
};
675675

676-
utils.beforeContext = function (contextGlobal) {
676+
utils.beforeContext = function(contextGlobal) {
677677
return Object_getOwnPropertyDescriptors(contextGlobal);
678-
}
678+
};
679679

680680
function descriptorDiff(a, b) {
681681
if (!a || !b) {
682682
return true;
683683
}
684+
685+
// eslint-disable-next-line no-self-compare
684686
if (a.value !== b.value && a.value === a.value && b.value === b.value) {
685687
// allow for NaN in value
686688
return true;
@@ -695,16 +697,18 @@
695697
}
696698
return false;
697699
}
698-
utils.afterContext = function (beforeDescriptors, contextGlobal, sandbox) {
700+
utils.afterContext = function(beforeDescriptors, contextGlobal, sandbox) {
699701
try {
700-
const afterDescriptors = Object_getOwnPropertyDescriptors(contextGlobal);
702+
const afterDescriptors =
703+
Object_getOwnPropertyDescriptors(contextGlobal);
701704
const beforeKeys = Object_keys(beforeDescriptors);
702705
const afterKeys = Object_keys(afterDescriptors);
703706

704707
for (const beforeKey of beforeKeys) {
705708
const beforeDescriptor = beforeDescriptors[beforeKey];
706709
const afterDescriptor = afterDescriptors[beforeKey];
707-
const sandboxDescriptor = Object_getOwnPropertyDescriptor(sandbox, beforeKey);
710+
const sandboxDescriptor =
711+
Object_getOwnPropertyDescriptor(sandbox, beforeKey);
708712
if (!afterDescriptor) {
709713
// The descriptor was removed
710714
if (sandboxDescriptor) {
@@ -719,7 +723,8 @@
719723
if (!sandboxDescriptor || sandboxDescriptor.configurable) {
720724
Object_defineProperty(sandbox, beforeKey, afterDescriptor);
721725
} else {
722-
// TODO: How can we handle this case? Node tries to avoid it, but we don't always
726+
// TODO: How can we handle this case? Node tries to avoid it, but
727+
// we don't always
723728
}
724729
}
725730
}
@@ -731,7 +736,8 @@
731736

732737
// This property is freshly added
733738
const afterDescriptor = afterDescriptors[afterKey];
734-
const sandboxDescriptor = Object_getOwnPropertyDescriptor(sandbox, afterKey);
739+
const sandboxDescriptor =
740+
Object_getOwnPropertyDescriptor(sandbox, afterKey);
735741
if (!sandboxDescriptor || sandboxDescriptor.configurable) {
736742
Object_defineProperty(sandbox, afterKey, afterDescriptor);
737743
} else {
@@ -741,7 +747,7 @@
741747
} catch (e) {
742748
// ignored;
743749
}
744-
}
750+
};
745751
}
746752

747753
patchErrorTypes();

deps/chakrashim/src/v8v8.cc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,12 @@ namespace tracing {
289289
jsrt::Unimplemented("TraceWriter");
290290
return 0;
291291
}
292+
293+
TraceWriter* TraceWriter::CreateJSONTraceWriter(std::ostream&,
294+
const std::string&) {
295+
jsrt::Unimplemented("TraceWriter");
296+
return 0;
297+
}
292298
} // namespace tracing
293299
} // namespace platform
294300
} // namespace v8

test/parallel/parallel.status

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ test-http-pipeline-flood : SKIP
5252
test-http-same-map : SKIP
5353
test-http2-server-rst-stream : SKIP
5454
test-inspect-async-hook-setup-at-inspect : SKIP
55+
test-inspector-multisession-js : SKIP
56+
test-inspector-multisession-ws : SKIP
5557
test-intl : SKIP
5658
test-memory-usage : SKIP
5759
test-module-main-extension-lookup : SKIP
@@ -68,8 +70,6 @@ test-repl-pretty-stack : SKIP
6870
test-repl-sigint : SKIP
6971
test-repl-tab-complete : SKIP
7072
test-string-decoder : SKIP
71-
test-inspector-multisession-ws : SKIP
72-
test-inspector-multisession-js : SKIP
7373

7474
# ChakraCore does not support the chrome tracing framework
7575
test-trace-events-all : SKIP

0 commit comments

Comments
 (0)