3e955b3f73
* Only keep JRE 8 and 14 in the build matrix. For #3377. * Run tests in GitHub Actions on each PR * Attempt to fix Postgres configuration * Set explicit password for Postgres on GitHub Actions * Set explicit password for MySQL and MariaDB * Fix credentials for postgres and mysql * Fix duplicate id in GitHub workflow * Fix creation of test_db on MySQL * Revert back to GH Action MySQL service * Populate initial test databases * Fix syntax of workflow file * Reorder steps to give more time for MySQL to boot * Run MySQL database as a service, forward ports to config * Reformat MySQL options * Fix YAML syntax * Add missing 'steps' field * Fix connection to MySQL and Postgres * Add back explicit database creation steps * Force TCP/IP connection for postgres * Remove explicit creation of test database for postgres * Fix Postgres and Mariadb configs * Fix parameter spelling for mariadb * Display MariaDB test configuration * Fix more inconsistent parameter names * Fix more inconsistent parameter names * Attempt to use Coveralls maven plugin instead of GH action * Fix workflow file * Enable submission to coveralls * Supply coveralls token * Remove Travis-specific configuration files * Also update appveyor script after rename of SQL files * Reintroduce packaging/test_pom.xml used by Appveyor * Update filenames in appveyor.yml
61 lines
1.5 KiB
YAML
61 lines
1.5 KiB
YAML
version: 1.0.{build}
|
|
|
|
services:
|
|
- mysql
|
|
- postgresql96
|
|
|
|
init:
|
|
- cmd: java -version 2>&1 | find "version"
|
|
|
|
clone_depth: 5
|
|
skip_branch_with_pr: true
|
|
|
|
environment:
|
|
JAVA_HOME: C:\Program Files (x86)\Java\jdk1.8.0
|
|
MAVEN_HOME: C:\Program Files (x86)\Apache\Maven
|
|
|
|
matrix:
|
|
fast_finish: true
|
|
|
|
build: off
|
|
|
|
# scripts to run before test
|
|
before_test:
|
|
- cmd: echo Running scripts before build...
|
|
- cmd: |-
|
|
PATH=C:\Program Files\PostgreSQL\9.6\bin\;C:\Program Files\MySQL\MySQL Server 5.7\bin\;%PATH%
|
|
SET MYSQL_PWD=Password12!
|
|
mysql -u root --password=Password12! -e "create database test_db;"
|
|
mysql -u root test_db --password=Password12! < extensions\database\tests\conf\test-mysql.sql
|
|
echo "localhost:*:test_db:postgres:Password12!" > C:\Program Files\PostgreSQL\9.6\pgpass.conf
|
|
echo "localhost:*:test_db:postgres:Password12!" > pgpass.conf
|
|
echo "localhost:*:test_db:postgres:Password12!" > %userprofile%\pgpass.conf
|
|
SET PGPASSFILE=C:\Program Files\PostgreSQL\9.6\pgpass.conf
|
|
SET PGPASSWORD=Password12!
|
|
SET PGUSER=postgres
|
|
createdb test_db
|
|
psql -U postgres test_db < extensions\database\tests\conf\test-pgsql.sql
|
|
|
|
copy extensions\database\tests\conf\appveyor_tests.xml extensions\database\tests\conf\tests.xml
|
|
copy packaging\test_pom.xml packaging\pom.xml
|
|
- cmd: |-
|
|
mvn process-resources
|
|
mvn install -DskipTests=true -Dmaven.javadoc.skip=true -B -V
|
|
|
|
test_script:
|
|
- cmd: echo Running test_script...
|
|
- cmd: >-
|
|
echo PATH is:
|
|
|
|
path
|
|
|
|
refine test
|
|
|
|
on_failure:
|
|
- cmd: |-
|
|
dir
|
|
|
|
cache:
|
|
- C:\Users\appveyor\.m2
|
|
|