Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- image: moodlehq/moodle-php-apache:7.2
- services:
- - mysql:5.7
- variables:
- MYSQL_DATABASE: "moodlestable"
- MYSQL_ROOT_PASSWORD: ""
- MYSQL_ALLOW_EMPTY_PASSWORD: "yes"
- before_script:
- # Update packages and install git.
- - apt-get update -qq
- - apt-get install -y -qq git
- - git --version
- - git config --global user.email "gitlab@example.com"
- - git config --global user.name "Gitlab Test"
- - git clone git://github.com/moodle/moodle.git moodle
- - cd moodle
- - git checkout MOODLE_38_STABLE
- # Install Moodle.
- - php admin/cli/install.php --non-interactive --wwwroot=http://localhost --fullname=test --shortname=test --adminpass=test --agree-license --dataroot=/var/www/moodledata --dbtype=mysqli --dbhost=mysql --dbuser=root --dbpass= --dbname=moodle --skip-database --allow-unstable
- # Inject the PHPUnit settings into the config.php file.
- - sed -i '25i$CFG->phpunit_prefix = "phpu_"; $CFG->phpunit_dataroot = "/var/www/phpunitdata";' config.php
- jobtest:
- script:
- # Initialize PHPunit.
- - php admin/tool/phpunit/cli/init.php
- - php admin/tool/phpunit/cli/util.php --buildcomponentconfigs
- # Run unit tests for the custom plugins on the site.
- - vendor/bin/phpunit
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement