Skip to content

Commit 069a128

Browse files
committed
updated readme and test harness
1 parent fd31d78 commit 069a128

2 files changed

Lines changed: 17 additions & 1 deletion

File tree

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@ Example of new method:
3333

3434
##### Old way #####
3535
node-libgit2 utilizes nodeunit `npm install nodeunit` or use `/vendor/nodeunit` to handle its tests in the
36-
`/test` folder. Example of running repo tests with vendor script:
36+
`/test` folder.
37+
38+
Example of running repo tests with vendor script:
3739
[tim@thinkpad Projects]$ cd node-libgit2
3840
[tim@thinkpad node-libgit2]$ node-waf configure build
3941
[tim@thinkpad node-libgit2]$ ./vendor/nodeunit/bin/nodeunit test/test-repo.js

test/index.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,19 @@ catch(e) {
1616
process.exit();
1717
}
1818

19+
try {
20+
var rimraf = require('../vendor/rimraf');
21+
}
22+
catch(e) {
23+
var sys = require('sys');
24+
sys.puts("Cannot find rimraf module.");
25+
sys.puts("You can download submodules for this project by doing:");
26+
sys.puts("");
27+
sys.puts(" git submodule init");
28+
sys.puts(" git submodule update");
29+
sys.puts("");
30+
process.exit();
31+
}
32+
1933
process.chdir('./');
2034
reporter.run(['test']);

0 commit comments

Comments
 (0)