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

Commit 1485314

Browse files
committed
Fix tests not build by default
1 parent efe74c6 commit 1485314

File tree

1 file changed

+36
-43
lines changed

1 file changed

+36
-43
lines changed

binding.gyp

Lines changed: 36 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -63,56 +63,49 @@
6363
]
6464
}],
6565
],
66+
},
67+
{
68+
"target_name": "tests",
69+
"type": "executable",
70+
"cflags_cc!": ["-fno-exceptions"],
71+
"defines": [
72+
"CATCH_CONFIG_CPP11_NO_IS_ENUM"
73+
],
74+
"sources": [
75+
"test/native/test-helpers.cc",
76+
"test/native/tests.cc",
77+
"test/native/encoding-conversion-test.cc",
78+
"test/native/patch-test.cc",
79+
"test/native/text-buffer-test.cc",
80+
"test/native/text-test.cc",
81+
"test/native/text-diff-test.cc",
82+
"benchmark/native/marker-index-benchmark.cc"
83+
],
84+
"include_dirs": [
85+
"vendor",
86+
"src/core",
87+
],
88+
"dependencies": [
89+
"superstring_core"
90+
],
91+
"conditions": [
92+
['OS=="mac"', {
93+
'cflags': [
94+
"-mmacosx-version-min=<(MACOSX_DEPLOYMENT_TARGET)"
95+
],
96+
"xcode_settings": {
97+
"GCC_ENABLE_CPP_EXCEPTIONS": "YES",
98+
'MACOSX_DEPLOYMENT_TARGET': '<(MACOSX_DEPLOYMENT_TARGET)',
99+
}
100+
}]
101+
]
66102
}
67103
],
68104

69105
"variables": {
70-
"tests": 0,
71106
"STANDARD": 17,
72107
"MACOSX_DEPLOYMENT_TARGET": "10.8"
73108
},
74-
75-
"conditions": [
76-
# If --tests is passed to node-gyp configure, we'll build a standalone
77-
# executable that runs tests on the patch.
78-
['tests != 0', {
79-
"targets": [{
80-
"target_name": "tests",
81-
"type": "executable",
82-
"cflags_cc!": ["-fno-exceptions"],
83-
"defines": [
84-
"CATCH_CONFIG_CPP11_NO_IS_ENUM"
85-
],
86-
"sources": [
87-
"test/native/test-helpers.cc",
88-
"test/native/tests.cc",
89-
"test/native/encoding-conversion-test.cc",
90-
"test/native/patch-test.cc",
91-
"test/native/text-buffer-test.cc",
92-
"test/native/text-test.cc",
93-
"test/native/text-diff-test.cc",
94-
],
95-
"include_dirs": [
96-
"vendor",
97-
"src/core",
98-
],
99-
"dependencies": [
100-
"superstring_core"
101-
],
102-
"conditions": [
103-
['OS=="mac"', {
104-
'cflags': [
105-
"-mmacosx-version-min=<(MACOSX_DEPLOYMENT_TARGET)"
106-
],
107-
"xcode_settings": {
108-
"GCC_ENABLE_CPP_EXCEPTIONS": "YES",
109-
'MACOSX_DEPLOYMENT_TARGET': '<(MACOSX_DEPLOYMENT_TARGET)',
110-
}
111-
}]
112-
]
113-
}]
114-
}]
115-
],
116109
"target_defaults": {
117110
"cflags_cc": [ "-std=c++<(STANDARD)" ],
118111
"conditions": [

0 commit comments

Comments
 (0)