Nik
December 30, 2015, 4:59am
1
WP-Cli , a command line interface for WordPress has a simple command to get started with Travis CI unit testing for any WordPress development projects.
In an issue on WP-Cli project, the team is going to add in a command that will automate default WordPress tesing on Gitlab Ci.
I have been already trying to set-up Gitlab CI for my WordPress projects, but not yet successful with it.
Has anyone had any success with setting up WordPress tests on Gitlab CI?
~ Nik
Nik
December 30, 2015, 7:19am
2
I have set up an existing project from Github to gitlab.com for setting up the unit testing, I have also set up a specific runner for the project.
Project can be found here , and it’s builds here
The project does not have any actual PHP unit test cases, I am just trying to set up the CI environment as of yet.
If you see the same commits are failing on Gitlab CI but are passing on Travis CI,
Travis CI build which is passing and Gitlab CI build which is failing for same commit.
Any info on this would be helpful.
axil
January 5, 2016, 10:25am
3
Hi @Nik sorry for the late reply. I’m gonna try to get to the bottom of this as there is a blog post coming about testing PHP apps. I may be able to have it sorted out this week.
Nik
January 5, 2016, 11:23am
4
Thank you @axil , Please let me know if there is any more info needed from my side for this, whether it may be testing .gitlab-ci.yml
.
Nik
January 8, 2016, 12:47pm
5
An update on this, I looked through core WordPress source code on the failing files, and saw that hey are using mysqli
So I installed mysqli docker extension, the builds are not "failing"
but the there are errors, It is not able to connect to mysql database.
GitLab.com
Nik
January 11, 2016, 6:30am
6
@axil : I did figure out what was wrong with my configuration, I was using wrong host this time. This issue is resolved now.
Thank you
2 Likes
under
June 22, 2016, 5:30am
7
@Nik I have checked you test-wp-plugin code, the run is made, but no test is verified, can you help me on that?