webrtc / KITE

KITE is a test engine designed to test WebRTC interoperability across browsers
Apache License 2.0
468 stars 126 forks source link

js test is broken #104

Closed Piasy closed 4 years ago

Piasy commented 4 years ago

Hi, in the KITE-AppRTC-Test dir, I can run the java test successfully with r configs/iceconnection.apprtc.config.json, but when run the js test with r configs/js.iceconnection.apprtc.config.json, it fail with:

 Process exited with result 0 and output TypeError: Cannot read property 'toLocaleUpperCase' of undefined
    at createWebDriver (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/kite-common/wdmgmt/WebDriverFactory.js:38:29)
    at Object.getDriver (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/kite-common/wdmgmt/WebDriverFactory.js:94:25)
    at IceConnectionTest.testScript (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/IceConnectionTest.js:15:44)
    at IceConnectionTest.run (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/kite-common/util/KiteBaseTest.js:106:18)
    at /Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/IceConnectionTest.js:49:14
    at process._tickCallback (internal/process/next_tick.js:68:7)
    at Function.Module.runMain (internal/modules/cjs/loader.js:745:11)
    at startup (internal/bootstrap/node.js:283:19)
    at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)
TypeError: Cannot read property 'quit' of undefined
    at IceConnectionTest.testScript (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/IceConnectionTest.js:39:25)
    at process._tickCallback (internal/process/next_tick.js:68:7)
    at Function.Module.runMain (internal/modules/cjs/loader.js:745:11)
    at startup (internal/bootstrap/node.js:283:19)
    at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)
namvuCosmo commented 4 years ago

Hi,

Sorry but currently we don't have the bandwidth to maintain the js codes, only java. We will look into this in the future.

Piasy commented 4 years ago

Okay, thanks for the information.

BTW, how could we test native WebRTC Apps on Android/iOS/macOS/Windows/Linux with KITE?

namvuCosmo commented 4 years ago

Well for testing native apps, you will need a few things:

We are preparing some documentations and example test on this. I'll let you know when they will be ready.

namvuCosmo commented 4 years ago

Unrelated to the native app things, but to the topic of this issue. I just push a new update code that's supposed to fix the js tests. Can you give it a try and let me know if there's any further issue?

Piasy commented 4 years ago

Hi @namvuCosmo , I tried your commit, it now fails with this error:

 Process exited with result 0 and output Error: The ChromeDriver could not be found on the current PATH. Please download the latest version of the ChromeDriver from http://chromedriver.storage.googleapis.com/index.html and ensure it can be found on your PATH.
    at new ServiceBuilder (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/selenium-webdriver/chrome.js:173:13)
    at Function.getDefaultService (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/selenium-webdriver/chrome.js:212:22)
    at Function.createSession (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/selenium-webdriver/chromium.js:582:49)
    at Function.createSession (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/selenium-webdriver/chrome.js:289:41)
    at createDriver (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/selenium-webdriver/index.js:155:33)
    at Builder.build (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/selenium-webdriver/index.js:662:16)
    at createWebDriver (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/kite-common/wdmgmt/WebDriverFactory.js:56:10)
    at Object.getDriver (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/kite-common/wdmgmt/WebDriverFactory.js:95:25)
    at IceConnectionTest.testScript (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/IceConnectionTest.js:15:44)
    at IceConnectionTest.run (/Users/piasy/src/media/KITE/KITE-AppRTC-Test/js/node_modules/kite-common/util/KiteBaseTest.js:106:18)
wrote all data to file

How could I configure PATH to let js test can call chrome driver?

namvuCosmo commented 4 years ago

Thanks for the response. For this you can just add the chromedriver and geckodriver to your system's path variables.

But this is not the solution. I thought it was a PATH issue in the beginning as well, but it turned out to be a remote address forwarding stuff. I'm fixing it.