I'm trying to build a CodeCeption acceptance test environment for Joomla. To make it easier to reproduce the tests on any developer's machine, I want to provide a Docker based environment.
I'm creating the environment using docker-compose:
web:
image: php:5-apache
volumes:
- ../..:/var/www/html
ports:
- 8080:80
links:
- db:db
db:
image: mysql
volumes:
- ../../tests/_envs/sql:/var/lib/mysql
ports:
- 3306:3306
hub:
image: selenium/hub
ports:
- 4444:4444
firefox:
image: selenium/node-firefox-debug
ports:
- 5900
links:
- hub:hub
The CodeCeption setup looks like this (JoomlaBrowser is just extending WebDriver, adding Joomla specific functionality):
class_name: AcceptanceTester
modules:
enabled:
- JoomlaBrowser:
url: 'http://localhost:8080/' # the url that points to the joomla installation at /tests/system/joomla-cms
browser: 'firefox'
window_size: 1024x768
capabilities:
unexpectedAlertBehaviour: 'accept'
username: 'admin'
password: 'admin'
database host: 'localhost' # place where the Application is Hosted #server Address
database user: 'root' # MySQL Server user ID, usually root
database password: '1234' # MySQL Server password, usually empty or root
database name: 'dbname' # DB Name, at the Server
database type: 'mysqli' # type in lowercase one of the options: MySQL\MySQLi\PDO
database prefix: 'jos_' # DB Prefix for tables
install sample data: 'Yes' # Do you want to Download the Sample Data Along with Joomla Installation, then keep it Yes
sample data: 'Default English (GB) Sample Data' # Default Sample Data
admin email: '[email protected]' # email Id of the Admin
language: 'English (United Kingdom)' # Language in which you want the Application to be Installed
joomla folder: '/home/.../path to Joomla Folder' # Path to Joomla installation where we execute the tests
- \Helper\Acceptance
error_reporting: E_ALL
Once started, the web environment is accessible through http://localhost:8080 (redirecting to installation/index.php on a fresh copy of Joomla as expected) manually. So is the Selenium grid at http://localhost:4444/grid/console. Nevertheless, when running a CodeCeption acceptance test, the test only sees the 'Problem loading page' browser message.
What did I miss?