Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update appveyor.yml #213

Merged
merged 15 commits into from
Aug 16, 2018
77 changes: 44 additions & 33 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,72 +2,83 @@
# http://www.appveyor.com/docs/appveyor-yml

# Set build version format here instead of in the admin panel.
version: 2.13-dev-{build}
version: 2.17-dev-{build}

clone_folder: C:\projects\eccube2

cache:
- '%LOCALAPPDATA%\Composer\files'
- data\vendor

# Fix line endings in Windows. (runs before repo cloning)
init:
- git config --global core.autocrlf input

environment:
global:
USER: "postgres"
USER: "root"
DBNAME: "myapp_test"
DBPASS: "Password12!"
DBUSER: "postgres"
DBUSER: "root"
DBSERVER: "localhost"
BASE_DIR: "C:/projects/ec-cube"

matrix:
- db: postgresql
provider: postgresql
- db: mysql
provider: mysql

services:
- iis
- postgresql93
- mysql

# Install scripts. (runs after repo cloning)
install:
# Set MySQL.
#- cp tests/my.cnf c:\
#- SET PATH=C:\Program Files\MySql\MySQL Server 5.7\bin\;%PATH%
- cinst -y OpenSSL.Light
- SET PATH=C:\Program Files\OpenSSL;%PATH%
- sc config wuauserv start= auto
- net start wuauserv
# Set postgresql.
- SET PGUSER=postgres
- SET PGPASSWORD=Password12!
- PATH=C:\Program Files\PostgreSQL\9.3\bin\;%PATH%
#- SET PGUSER=postgres
#- SET PGPASSWORD=Password12!
#- PATH=C:\Program Files\PostgreSQL\9.3\bin\;%PATH%
# Set MySQL.
- cp tests/my.cnf c:\
- SET PATH=C:\Program Files\MySql\MySQL Server 5.7\bin\;%PATH%
# Set bash.
#- cinst mingw-get
#- set PATH=%PATH%;C:\MinGW\msys\1.0\bin;C:\MinGW\bin
#- mingw-get install mingw-developer-toolkit
## Set PHP.
- cinst php -version 5.6.17 --allow-empty-checksums
- SET PATH=C:\tools\php\;%PATH%
- copy C:\tools\php\php.ini-production C:\tools\php\php.ini
- echo date.timezone="Asia/Tokyo" >> C:\tools\php\php.ini
- echo extension_dir=ext >> C:\tools\php\php.ini
- echo extension=php_openssl.dll >> C:\tools\php\php.ini
- echo extension=php_gd2.dll >> C:\tools\php\php.ini
- echo extension=php_mbstring.dll >> C:\tools\php\php.ini
- echo extension=php_mysql.dll >> C:\tools\php\php.ini
- echo extension=php_pgsql.dll >> C:\tools\php\php.ini
- echo extension=php_curl.dll >> C:\tools\php\php.ini
- echo output_buffering = Off >> C:\tools\php\php.ini
- echo default_charset = UTF-8 >> C:\tools\php\php.ini
- echo mbstring.language = Japanese >> C:\tools\php\php.ini
- echo mbstring.encoding_translation = On >> C:\tools\php\php.ini
- echo mbstring.http_input = UTF-8 >> C:\tools\php\php.ini
- echo mbstring.http_output = pass >> C:\tools\php\php.ini
- echo mbstring.internal_encoding = UTF-8 >> C:\tools\php\php.ini
- cinst php --allow-empty-checksums
- SET PATH=C:\tools\php72\;%PATH%
- cd c:\tools\php72
- copy php.ini-production php.ini
- echo date.timezone="Asia/Tokyo" >> php.ini
- echo extension_dir=ext >> php.ini
- echo extension=php_openssl.dll >> php.ini
- echo extension=php_gd2.dll >> php.ini
- echo extension=php_mbstring.dll >> php.ini
- echo extension=php_pgsql.dll >> php.ini
- echo extension=php_mysqli.dll >> php.ini
- echo extension=php_pdo_mysql.dll >> php.ini
- echo extension=php_pdo_pgsql.dll >> php.ini
- echo extension=php_curl.dll >> php.ini
- echo output_buffering = Off >> php.ini
- echo default_charset = UTF-8 >> php.ini
- echo mbstring.language = Japanese >> php.ini
- echo mbstring.encoding_translation = On >> php.ini
- echo mbstring.http_input = UTF-8 >> php.ini
- echo mbstring.http_output = pass >> php.ini
- echo mbstring.internal_encoding = UTF-8 >> php.ini
- cd C:\projects\eccube2
- php -r "readfile('https://getcomposer.org/installer');" | php
- php composer.phar install

# Don't actually build.
build: off

before_test:
- bash eccube_install.sh appveyor
- cp tests/require.php.jenkins tests/require.php
- bash eccube_install.sh mysql

test_script:
- vendor\bin\phpunit.bat
- data/vendor/bin/phpunit
2 changes: 1 addition & 1 deletion eccube_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ case "${DBTYPE}" in
#echo "grant user..."
#${MYSQL} -u ${ROOTUSER} ${PASSOPT} -e "GRANT ALL ON \`${DBNAME}\`.* TO '${DBUSER}'@'%' IDENTIFIED BY '${DBPASS}'"
echo "create table..."
echo "SET SESSION storage_engine = InnoDB;" |
echo "SET SESSION default_storage_engine = InnoDB;" |
cat - ${SQL_DIR}/create_table_mysqli.sql |
${MYSQL} -u ${DBUSER} ${PASSOPT} ${DBNAME}
echo "insert data..."
Expand Down
6 changes: 2 additions & 4 deletions tests/my.cnf
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
[mysqld]
#default-character-set=utf8
character-set-server = utf8
skip-character-set-client-handshake
#collation-server = utf8_general_ci
#max_prepared_stmt_count=2000000

[client]
default-character-set=utf8
#character-set-server = utf8
user = root
password = Password12!