Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
92 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
work | ||
work-* | ||
snapshot | ||
work/ | ||
work-*/ | ||
snapshot/ | ||
dashboard.html | ||
edition4/.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
Quick Start | ||
========= | ||
|
||
Install [vagrant](http://www.vagrantup.com/). | ||
|
||
Tweak `awdwr/vagrant/Vagrantfile` if necessary, then run the following command | ||
to install and configure everything needed to run the Agile Web Development | ||
with Rails tests using Vagrant: | ||
|
||
cd awdwr/vagrant; vagrant up | ||
|
||
Upon completion, the installation will report the address of the web | ||
interface. | ||
|
||
Using the Web Interface | ||
=== | ||
|
||
At the bottom of the table is an input field. Enter any combination of: | ||
|
||
- A one digit edition number for the book (currently only 4 is supported) | ||
- A two digit Rails version (e.g., 40 or 32) | ||
- A three digit Ruby version (e.g. 200 or 193) | ||
|
||
For convenience, you can click on a column header to sort by that column, and | ||
you can click on an individual time entry to pre-fill in the input field. By | ||
holding down the control key (command on Mac OS X) you can select multiple | ||
builds to be executed sequentially. | ||
|
||
Press submit. Status will show up at the bottom. The first time you run | ||
this, it will take some time as it will install the necessary version of Ruby | ||
and download gems and checkout repositories. Once it begins running the | ||
actual test you will be able to see what step it is running. | ||
|
||
In the top right is a link to the `logs` directory, which can be useful when | ||
things go wrong. | ||
|
||
Using the Command interface | ||
---- | ||
|
||
Before proceeding, a bit of knowledge as to how the directories are laid out | ||
is in order. As Rails is commonly used, one may have multiple applications | ||
and each is largely self contained. This test suite flips that around, one | ||
has multiple copies of the application(s) and a single checked out copy of | ||
each repository. | ||
|
||
vagrant ssh | ||
|
||
The command run by the web interface is `testrails` and it can be run directly | ||
from the command line. This does all of the necessary setup, steps that don't | ||
generally need to be repeated. | ||
|
||
More commonly, what is needed when running interactively is to make use of the | ||
existing repositories and directories. This involves a number of `git` | ||
commands and a final `cd` command. The `work` alias is set up to do this, and | ||
will allow you to switch quickly and easily from one configuration to another. | ||
Arguments to `work` are the same as to `testrails`, and default to whatever | ||
the current release is. At the moment, that is Book edition 4, Rails 40, and | ||
Ruby 200. | ||
|
||
From here, you can ruby `rails new` or `cd depot` and run `rails console` or | ||
`rails server`. Modify the application as you see fit, as it will be | ||
recreated from scratch on the next test run. | ||
|
||
Alternately, `depot` can be used to can run all or a subset of steps in the | ||
scenario by identifying the starting and stopping section numbers. For | ||
example, | ||
|
||
depot 6.1-10.1 | ||
|
||
This can be used in combination with `git bisect`: | ||
|
||
cd ~/git/rails | ||
git bisect start | ||
git bisect bad | ||
git checkout <revision> | ||
git bisect good | ||
git bisect run depot 6.1-10.1 | ||
|
||
Other possibilities include pulling or directly applying changes to rails or | ||
other dependencies and restarting the tests at any point. | ||
|
||
Cleaning up | ||
=== | ||
|
||
The entire vm can be removed using the following command: | ||
|
||
vagrant destroy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters