Skip to content

Commit

Permalink
build: enable cctest to use generated objects
Browse files Browse the repository at this point in the history
This commit tries to make it simpler to add unit tests (cctest) for
code that needs to test node core funtionality but that might not be
appropriate as an addon or a JavaScript test. An example of this could
be adding functionality targeted for situations when Node itself is
embedded.

Currently it was not as easy, or efficient, as one would have hoped to
add such tests. The object output directories vary for different
operating systems which we need to link to so that we don't have an
additional compilation step.

PR-URL: #11956
Ref: #9163
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
danbev authored and jasnell committed Mar 24, 2017
1 parent a8a042a commit 6a09a69
Show file tree
Hide file tree
Showing 7 changed files with 505 additions and 357 deletions.
6 changes: 4 additions & 2 deletions common.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@
['OS == "win"', {
'os_posix': 0,
'v8_postmortem_support%': 'false',
'OBJ_DIR': '<(PRODUCT_DIR)/obj',
'V8_BASE': '<(PRODUCT_DIR)/lib/v8_libbase.lib',
}, {
'os_posix': 1,
'v8_postmortem_support%': 'true',
Expand All @@ -51,8 +53,8 @@
'OBJ_DIR': '<(PRODUCT_DIR)/obj',
'V8_BASE': '<(PRODUCT_DIR)/obj/deps/v8/src/libv8_base.a',
}, {
'OBJ_DIR': '<(PRODUCT_DIR)/obj.target',
'V8_BASE': '<(PRODUCT_DIR)/obj.target/deps/v8/src/libv8_base.a',
'OBJ_DIR%': '<(PRODUCT_DIR)/obj.target',
'V8_BASE%': '<(PRODUCT_DIR)/obj.target/deps/v8/src/libv8_base.a',
}],
],
}],
Expand Down
Loading

0 comments on commit 6a09a69

Please sign in to comment.