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

Add Windows build script #428

Merged
merged 1 commit into from
Feb 24, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
108 changes: 108 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
build: false
platform: x86
clone_folder: c:\t3c
services:
- mysql

environment:
COMPOSER_NO_INTERACTION: 1
PHP: 1
TYPO3_PATH_WEB: 'c:\t3c\.Build\Web'

matrix:
- TYPO3_VERSION: '~8.6'
PHP_VERSION: '7.1.1'
- TYPO3_VERSION: '~8.6'
PHP_VERSION: '7.0.9'
- TYPO3_VERSION: '~7.6'
PHP_VERSION: '7.1.1'
- TYPO3_VERSION: '~7.6'
PHP_VERSION: '7.0.9'

matrix:
fast_finish: true

cache:
- c:\php -> appveyor.yml
- '%LOCALAPPDATA%\Composer\files'

init:
- SET PATH=c:\php;%PATH%

install:
- IF EXIST c:\php (SET PHP=0) ELSE (mkdir c:\php)
- cd c:\php
- IF %PHP%==1 appveyor DownloadFile http://windows.php.net/downloads/releases/archives/php-%PHP_VERSION%-nts-Win32-VC14-x86.zip
- IF %PHP%==1 7z x php-%PHP_VERSION%-nts-Win32-VC14-x86.zip -y >nul
- IF %PHP%==1 del /Q *.zip
- IF %PHP%==1 echo @php %%~dp0composer.phar %%* > composer.bat
- IF %PHP%==1 copy /Y php.ini-development php.ini
- IF %PHP%==1 echo max_execution_time=1200 >> php.ini
- IF %PHP%==1 echo date.timezone="UTC" >> php.ini
- IF %PHP%==1 echo extension_dir=ext >> php.ini
- IF %PHP%==1 echo extension=php_curl.dll >> php.ini
- IF %PHP%==1 echo extension=php_openssl.dll >> php.ini
- IF %PHP%==1 echo extension=php_mbstring.dll >> php.ini
- IF %PHP%==1 echo extension=php_fileinfo.dll >> php.ini
- IF %PHP%==1 echo extension=php_mysqli.dll >> php.ini
- appveyor DownloadFile https://getcomposer.org/composer.phar
- cd c:\t3c
- composer require "typo3/cms=%TYPO3_VERSION%" --prefer-dist --no-progress --ansi

test_script:
- cd c:\t3c
- .Build\bin\phpunit -c .Build/vendor/nimut/testing-framework/res/Configuration/UnitTests.xml Tests/Unit/
- php Scripts/typo3cms
- php Scripts/typo3cms install:setup --non-interactive --database-user-name="root" --database-user-password="Password12!" --database-host-name="localhost" --database-port="3306" --database-name="appveyor_test" --admin-user-name="admin" --admin-password="password" --site-name="Appveyor Install" --site-setup-type="createsite"
# - echo 'select uid,title from pages limit 1' | typo3cms database:import | sed 's/[[:blank:]]//g' | grep 1Home
- php Scripts/typo3cms help
- php Scripts/typo3cms help:autocomplete >nul
- php Scripts/typo3cms help:autocomplete bash >nul
- php Scripts/typo3cms help:autocomplete zsh >nul
- php Scripts/typo3cms backend:lock
- php Scripts/typo3cms backend:unlock
- php Scripts/typo3cms backend:lockforeditors
- php Scripts/typo3cms backend:unlockforeditors
- php Scripts/typo3cms cache:flush
- php Scripts/typo3cms cache:flushgroups pages
- php Scripts/typo3cms cache:flushtags foo
- php Scripts/typo3cms cache:flushtags foo pages
- php Scripts/typo3cms cache:listgroups
- php Scripts/typo3cms cleanup:updatereferenceindex
- php Scripts/typo3cms database:updateschema "*" --verbose --dry-run
- php Scripts/typo3cms database:updateschema --verbose
- php Scripts/typo3cms database:updateschema "*" --verbose
# - php Scripts/typo3cms database:export > travis_test.sql
# - test $(typo3cms database:export --exclude-tables sys_log | grep "CREATE TABLE" | grep -c sys_log) -eq 0
# - echo "SELECT username from be_users where admin=1;" | php Scripts/typo3cms database:import
# - echo "DROP DATABASE travis_test;" | php Scripts/typo3cms database:import
# - echo "CREATE DATABASE travis_test;" | mysql -uroot && cat travis_test.sql | php Scripts/typo3cms database:import
# - php Scripts/typo3cms database:updateschema "*" --verbose
- php Scripts/typo3cms frontend:request / >nul
- php Scripts/typo3cms documentation:generatexsd "TYPO3\CMS\Fluid\ViewHelpers" >nul
- php Scripts/typo3cms configuration:show BE/installToolPassword
- php Scripts/typo3cms configuration:showLocal BE/installToolPassword
- php Scripts/typo3cms configuration:showActive BE/installToolPassword
# - php Scripts/typo3cms configuration:set BE/installToolPassword foobar && grep installToolPassword $TYPO3_PATH_WEB/typo3conf/LocalConfiguration.php | grep foobar
# - php Scripts/typo3cms configuration:remove BE/installToolPassword --force && grep -qv installToolPassword $TYPO3_PATH_WEB/typo3conf/LocalConfiguration.php
# - php Scripts/typo3cms configuration:set BE/installToolPassword blablupp && grep installToolPassword $TYPO3_PATH_WEB/typo3conf/LocalConfiguration.php | grep blablupp
# - php Scripts/typo3cms configuration:set EXTCONF/lang/availableLanguages/1 fr_FR && grep fr_FR $TYPO3_PATH_WEB/typo3conf/LocalConfiguration.php
# - php Scripts/typo3cms configuration:set EXTCONF/foo/bar baz && grep bar $TYPO3_PATH_WEB/typo3conf/LocalConfiguration.php | grep baz
# - rm -f $TYPO3_PATH_WEB/typo3conf/PackageStates.php && php Scripts/typo3cms install:generatepackagestates --activate-default && [ -f "$TYPO3_PATH_WEB/typo3conf/PackageStates.php" ]
# - rm -f $TYPO3_PATH_WEB/typo3conf/PackageStates.php && TYPO3_CONSOLE_FEATURE_GENERATE_PACKAGE_STATES=yes TYPO3_CONSOLE_TEST_SETUP=yes TYPO3_ACTIVATE_DEFAULT_FRAMEWORK_EXTENSIONS=yes composer dump-autoload -vv 2>&1 | grep 'generated PackageStates.php' && [ -f "$TYPO3_PATH_WEB/typo3conf/PackageStates.php" ]
# - grep sys_note "$TYPO3_PATH_WEB/typo3conf/PackageStates.php"
# - rm $TYPO3_PATH_WEB/typo3temp/index.html && php Scripts/typo3cms install:fixfolderstructure && [ -f "$TYPO3_PATH_WEB/typo3temp/index.html" ]
- php Scripts/typo3cms extension:list
- php Scripts/typo3cms extension:list --raw
# - php Scripts/typo3cms extension:list --raw | grep extbase
- php Scripts/typo3cms extension:list --active --raw
# - php Scripts/typo3cms extension:list --active --raw | grep extbase
- php Scripts/typo3cms extension:list --inactive --raw
# - php Scripts/typo3cms extension:list --inactive --raw | tr '\n' ' ' | grep -v extbase
# - cp -r Tests/Functional/Fixtures/ext_test .Build/Web/typo3conf/ext/
# - php Scripts/typo3cms extension:activate ext_test && php Scripts/typo3cms cache:flush && php Scripts/typo3cms database:updateschema | grep 'No schema updates were performed'
# - php Scripts/typo3cms extension:activate core && php Scripts/typo3cms database:updateschema | grep 'No schema updates were performed'
# - php Scripts/typo3cms extension:setup core && php Scripts/typo3cms database:updateschema | grep 'No schema updates were performed'
# - php Scripts/typo3cms extension:setupactive && php Scripts/typo3cms database:updateschema | grep 'No schema updates were performed'
# - if php Scripts/typo3cms extension:list --raw | grep dbal; then php Scripts/typo3cms extension:activate adodb,dbal && php Scripts/typo3cms database:updateschema | grep 'No schema updates were performed'; fi
# - php Scripts/typo3cms extension:removeinactive --force | grep 'The following directories have been removed'