Skip to content

Commit

Permalink
TASK: Create the running Neos instance on TravisCI #18
Browse files Browse the repository at this point in the history
  • Loading branch information
Inkdpixels committed Feb 20, 2016
1 parent 6806440 commit ddfe8bd
Show file tree
Hide file tree
Showing 5 changed files with 2,983 additions and 3 deletions.
47 changes: 45 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,23 @@ sudo: false
language: node_js
notifications:
email: false
services:
- mysql
addons:
sauce_connect: true
matrix:
fast_finish: true
include:
- php: 7.0
env: DB=mysql

#
# Cache the node_modules directory to speeden up the `npm install` command.
# Cache the composer and node_modules directory to speeden up the the installation of dependencies.
#
cache:
directories:
- node_modules
- $HOME/.composer/cache

#
# Install dependencies for other services & expose the commit message for SauceLabs.
Expand All @@ -20,9 +28,44 @@ cache:
before_install:
- npm i -g codeclimate-test-reporter
- "export COMMIT_MESSAGE=\"$(git log --format=%B --no-merges -n 1)\""
- export FLOW_CONTEXT=Test

# Create the running neos instance for the behavior tests.
- cd ..
- composer self-update -q
- mkdir Neos
- cp PackageFactory.Guevara/Build/TravisCi/composer* Neos/
- cd Neos
- composer install -q
- mv ../PackageFactory.Guevara Packages/Application/

# Remove the default login package since our routes currenctly conflicts it.
- rm -rf Packages/Plugins/Flowpack.Neos.FrontendLogin

# Create the test database and move the configuration files into place.
- mysql -e 'create database neos collate utf8_unicode_ci;'
- cp Packages/Application/PackageFactory.Guevara/Build/TravisCi/Settings.yaml Configuration/Settings.yaml

# Setup the database scheme and import the demo site package.
- ./flow cache:warmup
- ./flow doctrine:migrate
- ./flow site:import --package-key=TYPO3.NeosDemoTypo3Org

# Create the demo backend user.
- ./flow user:create --username=johndoe --password=demo --first-name=John --last-name=Doe --roles=TYPO3.Neos:Administrator

# Start the development server.
- ./flow server:run --port 8081 &

# Give the server some time to start...
- sleep 3

# Change back into the repository directory where the tests will be executed.
- cd Packages/Application/PackageFactory.Guevara

#
# Since we cache the node_modules folder, we should prune it to remove extranous packages from older runs.
# Since we cache the node_modules folder,
# we should prune it to remove extranous packages from older runs.
#
before_script:
- npm prune
Expand Down
2 changes: 1 addition & 1 deletion Build/Selenium/Settings.yaml.example
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ WebdriverIO:
url: 'http://127.0.0.1:8081/che!'
credentials:
username: 'johndoe'
password: 'johndoespassword'
password: 'demo'
10 changes: 10 additions & 0 deletions Build/TravisCi/Settings.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
TYPO3:
Imagine:
driver: Gd
Flow:
persistence:
backendOptions:
driver: pdo_mysql
dbname: neos
user: root
host: 127.0.0.1
44 changes: 44 additions & 0 deletions Build/TravisCi/composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"name": "typo3/neos-base-distribution",
"description": "Neos Base Distribution",
"license": "GPL-3.0+",
"support": {
"email": "hello@neos.io",
"slack": "http://slack.neos.io/",
"forum": "https://discuss.neos.io/",
"wiki": "https://discuss.neos.io/c/the-neos-project/project-documentation",
"issues": "https://jira.neos.io/browse/NEOS",
"docs": "http://neos.readthedocs.org/",
"source": "https://github.com/neos/neos-base-distribution"
},
"config": {
"vendor-dir": "Packages/Libraries",
"bin-dir": "bin"
},
"require": {
"typo3/neos": "~2.1.0",
"typo3/neos-nodetypes": "~2.1.0",
"typo3/neosdemotypo3org": "~2.1.0",
"typo3/neos-kickstarter": "~2.1.0",
"typo3/neos-seo": "@dev",
"typo3/imagine": "@dev",
"typo3/twitter-bootstrap": "@dev",
"typo3/form": "@dev",
"typo3/setup": "@dev"
},
"require-dev": {
"typo3/buildessentials": "3.1.x-dev",
"mikey179/vfsstream": "~1.6",
"phpunit/phpunit": "~4.8 || ~5.0",
"flowpack/behat": "dev-master"
},
"suggest": {
"ext-pdo_sqlite": "For running functional tests out-of-the-box this is required"
},
"scripts": {
"post-update-cmd": "TYPO3\\Flow\\Composer\\InstallerScripts::postUpdateAndInstall",
"post-install-cmd": "TYPO3\\Flow\\Composer\\InstallerScripts::postUpdateAndInstall",
"post-package-update": "TYPO3\\Flow\\Composer\\InstallerScripts::postPackageUpdateAndInstall",
"post-package-install": "TYPO3\\Flow\\Composer\\InstallerScripts::postPackageUpdateAndInstall"
}
}

0 comments on commit ddfe8bd

Please sign in to comment.