Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 305d340

Browse filesBrowse files
rvaggMyles Borins
authored andcommitted
test: test each block in addon.md contains js & cc
Allows more freedom in adding additional headings to addon.markdown, otherwise it'll try and convert each block under a heading to a test case. We need to have at least a .js and a .cc in order to have something to test. Fixes regression caused by adding a new 3rd-level heading in d5863bc PR-URL: #4411 Reviewed-By: Myles Borins <myles.borins@gmail.com>
1 parent 75b0ea8 commit 305d340
Copy full SHA for 305d340

File tree

Expand file treeCollapse file tree

1 file changed

+7
-0
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+7
-0
lines changed
Open diff view settings
Collapse file

‎tools/doc/addon-verify.js‎

Copy file name to clipboardExpand all lines: tools/doc/addon-verify.js
+7Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,20 @@ function once(fn) {
5151
function verifyFiles(files, onprogress, ondone) {
5252
var dir = path.resolve(verifyDir, 'doc-' + id++);
5353

54+
// must have a .cc and a .js to be a valid test
55+
if (!Object.keys(files).some((name) => /\.cc$/.test(name)) ||
56+
!Object.keys(files).some((name) => /\.js$/.test(name))) {
57+
return;
58+
}
59+
5460
files = Object.keys(files).map(function(name) {
5561
return {
5662
path: path.resolve(dir, name),
5763
name: name,
5864
content: files[name]
5965
};
6066
});
67+
6168
files.push({
6269
path: path.resolve(dir, 'binding.gyp'),
6370
content: JSON.stringify({

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.