Adding test file path as argument of the rtcBot run command's arguments.

The new command to run rtcBot is:-
node test.js <bot_type> <test_file_path>

R=andresp@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/31419004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@7263 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
houssainy@google.com 2014-09-22 15:24:56 +00:00
parent 64a2f10f4b
commit 35850ff71f

View File

@ -76,10 +76,10 @@ Test.prototype = {
},
}
function runTest(testfile) {
function runTest(botType, testfile) {
console.log("Running test: " + testfile);
var script = vm.createScript(fs.readFileSync(testfile), testfile);
script.runInNewContext({ test: new Test(process.argv[2]) });
script.runInNewContext({ test: new Test(botType) });
}
runTest("./test/webrtc_video_streaming.js");
runTest(process.argv[2], process.argv[3]);