File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change 4444 - ' 8.0'
4545 - ' 8.1'
4646 services :
47- mongo :
48- image : mongo:${{ matrix.mongodb }}
49- ports :
50- - 27017:27017
5147 mysql :
5248 image : mysql:5.7
5349 ports :
5955
6056 steps :
6157 - uses : actions/checkout@v2
58+ - name : Create MongoDB Replica Set
59+ run : |
60+ docker run --name mongodb -p 27017:27017 -e MONGO_INITDB_DATABASE=unittest --detach mongo:${{ matrix.mongodb }} mongod --replSet rs
61+ until docker exec --tty mongodb mongo 127.0.0.1:27017 --eval "db.serverStatus()"; do
62+ sleep 1
63+ done
64+ sudo docker exec --tty mongodb mongo 127.0.0.1:27017 --eval "rs.initiate({\"_id\":\"rs\",\"members\":[{\"_id\":0,\"host\":\"127.0.0.1:27017\" }]})"
6265 - name : " Installing php"
6366 uses : shivammathur/setup-php@v2
6467 with :
8891 run : |
8992 ./vendor/bin/phpunit --coverage-clover coverage.xml
9093 env :
91- MONGODB_URI : ' mongodb://127.0.0.1/'
94+ MONGODB_URI : ' mongodb://127.0.0.1/?replicaSet=rs '
9295 MYSQL_HOST : 0.0.0.0
9396 MYSQL_PORT : 3307
9497 - uses : codecov/codecov-action@v1
You can’t perform that action at this time.
0 commit comments