Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Task after webdriver_standalone is not running. #96

Closed
Bsunny opened this issue Sep 15, 2017 · 3 comments
Closed

Task after webdriver_standalone is not running. #96

Bsunny opened this issue Sep 15, 2017 · 3 comments

Comments

@Bsunny
Copy link

Bsunny commented Sep 15, 2017

I need to run following tasks one after other:

  1. Webdriver-manager update
  2. Webdriver-manager start
  3. Run my scripts

Problem:
Task 1 ran --> after that Task 2 ran --> but Task 3 DID NOT ran...

On the command prompt, it stuck after this line.
23:08:49.060 INFO - Selenium Server is up and running

My gulp file has following:

var gulp = require('gulp');
var runSequence = require('run-sequence');
var protractor = require('gulp-protractor').protractor;
var webdriver_update = require('gulp-protractor').webdriver_update;
var webdriver_standalone = require('gulp-protractor').webdriver_standalone;

gulp.task('default', function (callback) {
    runSequence('webdriver_update', 'webdriver_standalone', 'run_scripts', function () {
            console.log('AABB');
            callback;
    });
});


gulp.task('webdriver_update',webdriver_update);
gulp.task('webdriver_standalone',webdriver_standalone);
gulp.task('run_scripts', function () {
    gulp.src(['./specs/LoginPage/*specs.js'])
        .pipe(protractor({
            configFile: "conf.js"
        }))
        .on('error', function(e){
            throw e
        });
});
@OverZealous
Copy link
Owner

It appears that your tasks aren't configured correctly for asynchronous processes. Please read the documentation.

If the tasks don't return something (promise, stream, callback), or they never complete, then run-sequence cannot determine when to start the next task.

@Bsunny
Copy link
Author

Bsunny commented Sep 24, 2017

It is 'webdriver_standalone' task that is not returning anything. Can you please help me to make it return, what code should I write ?

@OverZealous
Copy link
Owner

This is then a Gulp or webdriver issue, not run-sequence. run-sequence simply asks gulp to run the specific tasks. It listens for a task to end before starting the next. If a task never ends, then it cannot start the next one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants