Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Facing Null pointer while accessing the resource folders in Bitbucket pipeline

Hi All,

I am new to bitbucket pipeline and wanting to run my Selenium functional automated test using the bitbucket infrastructure.

I have a Java based project with Maven as the build management tool. I have tried executing the maven command to run the code on the linux instance but apparently getting Null pointer exception for a resource file as below /opt/atlassian/pipelines/agent/build/src/test/resources/testdata/Contact/CreateContact.json (No such file or directory)
at Method)

I have tried logging in the directory files and but it shows that my files are not cloned in the instance created.

This is the yml file I have created.

image: jamesdbloom/docker-java8-maven

depth: full

- parallel:
- step:
name: Build and Test
- maven
- docker run -d -p 4444:4444 --shm-size=2g selenium/standalone-chrome:3.141.59-20210607
- mvn -B verify -Dcucumber.filter.tags="$TAGS" -Dbrowser.type=$BROWSER -DEnvironment=$ENVT -DrunOnRemote=$ON_REMOTE -Dwebdriver.remote.url=$WD_URL
- docker
- target/**.
Attached is the project sturcutre for your reference.

1 answer

1 accepted

1 vote
Answer accepted

The folder name is Case sensitive, "testdata" folder name should be  testData. 

Refer this -

Thanks for the response @Honey Bhatnagar

This seems to have fixed the issue I am facing. 

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bitbucket

📣 Calling Bitbucket Data Center customers to participate in research

Hi everyone, Are you Bitbucket DC customer? If so, we'd love to talk to you! Our team wants to dive deep to understand your long-term plans regarding Bitbucket DC and Atlassian Cloud. Do you plan...

224 views 2 5
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you