README.md in akephalos2-2.0.1 vs README.md in akephalos2-2.0.2
- old
+ new
@@ -34,22 +34,26 @@
``` ruby
gem 'akephalos', :git => 'git://github.com/Nerian/akephalos.git'
```
-
# Development
+<img src="https://secure.travis-ci.org/Nerian/akephalos2.png?branch=master&.png">
+
``` bash
git clone https://github.com/Nerian/akephalos2
git submodule update --init
-# optional
-cp .rvmrc.example .rvmrc
```
The last line will grab the HTMLUnit jar files from [https://github.com/Nerian/html-unit-vendor](https://github.com/Nerian/html-unit-vendor)
+Also, we have a .rvmrc file already cooked:
+
+``` bash
+cp .rvmrc.example .rvmrc
+```
## Setup
Configuring akephalos is as simple as requiring it and setting Capybara's
javascript driver:
@@ -80,10 +84,36 @@
it "returns results" { page.should have_css("#results") }
it "includes the search term" { page.should have_content("akephalos") }
end
end
```
-
+
+Capybara allows you to perform your action on a context, for example inside a div or a frame. With Akephalos you can select the frame either by id or by index.
+
+``` html
+<body>
+ <p id="test">Test</p>
+ <iframe id="first" src="/one_text"></iframe>
+ <p id="test2">Test2</p>
+ <iframe class="second" src="/two_text"></iframe>
+ <p id="test3">Test3</p>
+ <iframe id="third" src="/three_text"></iframe>
+</body>
+```
+
+You can operate within the context of iframe `test2` with any of these calls:
+
+``` ruby
+# By ID
+within_frame("test2") do
+ ....
+end
+
+# By index
+within_frame(1) do
+ ....
+end
+```
## Configuration
There are now a few configuration options available through Capybara's new
`register_driver` API.