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 local-development.md #186

Merged
merged 1 commit into from
Jun 21, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions template/readme/local-development.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,24 @@ There are also other changes you can make if you choose to match the Acquia Clou

Once you've made these changes and completed the steps in Drupal VM's Quick Start Guide, you may run `vagrant up` to bring up your local development environment, and then access the site via the configured `drupal_domain`.

### Drupal VM and Behat tests

#### Using the Drupal Extension's "drupal" driver with Drupal VM

The Drupal Extension for Behat has an [inherent limitation](https://behat-drupal-extension.readthedocs.io/en/3.1/drivers.html): it cannot use the 'drupal' driver to bootstrap Drupal on a remote server. If you're using Drupal VM and would like to execute Behat tests using the 'drupal' driver, you must execute them from within the VM. This is a break of the established pattern of running all BLT commands outside of the VM.

To execute Behat tests using the 'drupal' driver on a Drupal VM environment, you must do the following:

1. Update `tests/behat/local.yml` with the absolute file path to your project _inside the VM_. I.e., find and replace all instances of `host/machine/path/to/repo` with `/vm/path/to/repo`, which should look something like `var/www/[project.machine_name]`.
1. SSH into the VM `vagrant ssh`.
1. Change to your project directory `cd /var/www/[project.machine_name]`.
1. Assert that PhantomJS is installed for VM: `composer run-script install-phantomjs`
1. Execute behat tests `./blt.sh tests:behat`

#### Using the Drupal Extension's "drush" driver with Drupal VM

You may choose to write only behat tests that utilize the Drupal Extension's "drupal" driver. Doing this will allow you to run `./blt.sh tests:behat` from the host machine without modificaitons to the Behat local.yml configuration.

## <a name="dd"></a>Using Acquia Dev Desktop for BLT-generated projects

### Project creation and installation changes
Expand Down