Hi All, Running an automated test with Selenium- built on MAvan Java running it with TestNG runner class. it fails with
Java Maven CircleCI 2.0 configuration file
Check Language Guide: Java - CircleCI for more details
version: 2
jobs:
build:
docker:
# specify the version you desire here
- image: circleci/openjdk:8-jdk
# Specify service dependencies here if necessary
# CircleCI maintains a library of pre-built images
# documented at https://circleci.com/docs/2.0/circleci-images/
# - image: circleci/postgres:9.4
working_directory: ~/circleCiTesting
environment:
# Customize the JVM maximum heap limit
MAVEN_OPTS: -Xmx3200m
steps:
- checkout
# Download and cache dependencies
- restore_cache:
keys:
- v1-dependencies-{{ checksum "pom.xml" }}
# fallback to using the latest cache if no exact match is found
- v1-dependencies-
- run: mvn dependency:go-offline
- run:
name: Install latest version of ChromeDriver Sample
command: |
sudo wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
sudo sudo sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list'
sudo apt-get update
sudo apt-get install google-chrome-unstable
- run:
name: Install latest version of ChromeDriver Sample
command: |
sudo wget https://chromedriver.storage.googleapis.com/2.31/chromedriver_linux64.zip
sudo unzip chromedriver_linux64.zip
sudo rm chromedriver_linux64.zip
sudo mv chromedriver /usr/bin/
sudo chmod 777 /usr/bin/chromedriver
sudo apt-get install libxi6 libgconf-2-4
sudo apt-get -y install xvfb gtk2-engines-pixbuf
sudo apt-get -y install xfonts-cyrillic xfonts-100dpi xfonts-75dpi xfonts-base xfonts-scalable
sudo apt-get install xvfb
sudo apt-get -y install imagemagick x11-apps
- run:
name: Running X virtual framebuffer
command: Xvfb :0 -ac &
- run:
name: Run Tests
command: |
export DISPLAY=:99
- save_cache:
paths:
- ~/.m2
key: v1-dependencies-{{ checksum "pom.xml" }}
# run tests!
- run: mvn test
- store_artifacts:
path: target/surefire-reports
destination: tr1
- store_test_results:
path: target/surefire-reports
Can someone help to resolve this issue?? Thanks in Advance