2017-02-08 8 views
2

Ich beginne mit Eclipse, konfiguriert, alles zu verwenden Winkelmesser, NodeJS, Transporteur, WebDriver, aber beim Debuggen oder wenn ich den Test ausführen möchten, es zurückgeben immer diese unerwartete TokenProtractor Syntaxerror: unerwartete Token

Konfigurationsdatei :

exports.config = { 
    // The address of a running selenium server. 
    seleniumAddress: 'http://localhost:4444/wd/hub', 

    // Capabilities to be passed to the webdriver instance. 
    capabilities: { 
    'browserName': 'chrome' 
    }, 

    // Spec patterns are relative to the configuration file location passed 
    // to protractor (in this example conf.js). 
    // They may include glob patterns. 
    specs: ['example-spec.js'], 

    // Options to be passed to Jasmine-node. 
    jasmineNodeOpts: { 
    showColors: true, // Use colors in the command line report. 
    } 
}; 

Fehler:

C:\Users\tgv\workspace\test7\node_modules\protractor\built\logger.js:75 
    info(...msgs) { 
     ^^^ 

SyntaxError: Unexpected token ... 
    at exports.runInThisContext (vm.js:53:16) 
    at Module._compile (module.js:414:25) 
    at Object.Module._extensions..js (module.js:442:10) 
    at Module.load (module.js:356:32) 
    at Function.Module._load (module.js:313:12) 
    at Module.require (module.js:366:17) 
    at require (module.js:385:17) 
    at Object.<anonymous> (C:\Users\tgv\workspace\test7\node_modules\protractor\built\configParser.js:5:18) 
    at Module._compile (module.js:435:26) 
    at Object.Module._extensions..js (module.js:442:10) 

Antwort

1

Haben Sie die neueste Version von NodeJS bekommen?

Ich lief in ein ähnliches Problem, das durch die Aktualisierung Knoten

+0

Hier gilt das gleiche festgelegt wurde. Ich habe den Winkelmesser in meinem Eclipse-Projekt mit dem npm install progractor installiert. Ich denke, es wird die letzte Version. –

+0

Dies ist die richtige Antwort. – Sam

Verwandte Themen