Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,560,304
Community Members
 
Community Events
185
Community Groups

How to run Selenium side runner in bitbucket pipeline?

I have tried running selenium side runner via Jenkins using below command:

selenium-side-runner -c "browserName=chrome goog:chromeOptions.args=[disable-infobars,headless]" myfile.side

Not sure how to run my tests in the pipeline, however, I tried below approach, but pipeline is failing:

image: atlassian/default-image:3

pipelines:
default:
- parallel:
- step:
name: 'Build and Test'
script:
- echo "Your build and test goes here..."
- step:
name: 'Lint'
script:
- echo "Your linting goes here..."
- step:
name: 'Security scan'
script:
- selenium-side-runner -c "browserName=chrome goog:chromeOptions.args=[disable-infobars,headless]" ./myfile.side
Error: Untitled.png

2 answers

0 votes
Mahmoud Sameer
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
Jan 13, 2023

Hi 
did u find the solution? 

0 votes
Igor Stoyanov
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Dec 10, 2021 • edited

@Divyanka  hi. Thanks for your question.

Try to use docker image with selenium-side-runner. As an example this image.

step:
name'Security scan'
image: nixel2007/docker-selenium-side-runner:latest
script:
selenium-side-runner -c "browserName=chrome goog:chromeOptions.args=[disable-infobars,headless]" ./myfile.side

Regards, Igor

Hi, @Igor Stoyanov can you please share your pipeline yml file for the reference

Igor Stoyanov
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Dec 13, 2021 • edited

@Divyanka hi. Try this one:

image:
name: atlassian/default-image:3

test: &test
parallel:
- step:
name: 'Build and Test'
script:
- echo "Your build and test goes here..."
- step:
name: 'Lint'
script:
- echo "Your linting goes here..."
- step:
name: 'Security scan'
image: nixel2007/docker-selenium-side-runner:latest
script:
- selenium-side-runner -c "browserName=chrome goog:chromeOptions.args=[disable-infobars,headless]" ./myfile.side


pipelines:
default:
- <<: *test
branches:
master:
- <<: *test

Also additionally you can try  this guide or this guide.

Regards, Igor.

Like Divyanka likes this

Thanks I tried, I was getting error: ChromeDriver not found, then I tried pulling headless chrome, still getting this error:

image.png

YML file: 

image: atlassian/default-image:3

 

pipelines:

  default:

       - step:

          name: Build and test

          image: zenika/alpine-chrome

          caches:

          - node

          script:

            - docker version

            - docker pull browserless/chrome:latest

          services:

            - docker

         

       - step:

          name: 'Test'

          image: nixel2007/docker-selenium-side-runner:latest

          script:

            - selenium-side-runner -c "browserName=chrome goog:chromeOptions.args=[disable-infobars,headless]" ./ConsoleTesting.side

 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events