diff options
author | sdelano <stephen@opscode.com> | 2010-06-02 20:00:08 -0700 |
---|---|---|
committer | Daniel DeLeo <dan@opscode.com> | 2010-06-03 12:22:15 -0700 |
commit | 09c6e842967856a93bb3ee53444901232af372d6 (patch) | |
tree | 2b425109fa7e05041986083e06350a7dbccf28ba /features/api/search/show_search.feature | |
parent | ae3cdccbdfe9daabf359ce774499a5c969497722 (diff) | |
download | chef-09c6e842967856a93bb3ee53444901232af372d6.tar.gz |
refactor feature tests:
* make_admin / make_non_admin
* rename response to api_response
Diffstat (limited to 'features/api/search/show_search.feature')
-rw-r--r-- | features/api/search/show_search.feature | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/features/api/search/show_search.feature b/features/api/search/show_search.feature index 41ea0397af..74dc011d96 100644 --- a/features/api/search/show_search.feature +++ b/features/api/search/show_search.feature @@ -5,7 +5,7 @@ Feature: Search data via the REST API I want to search the objects Scenario: Search for objects when none have been created - Given a 'registration' named 'bobo' exists + Given I am an administrator And a 'data_bag' named 'users' exists When I authenticate as 'bobo' And I 'GET' the path '/search/users' @@ -14,7 +14,7 @@ Feature: Search data via the REST API And the inflated responses key 'total' should be the integer '0' Scenario: Search for objects when one has been created - Given a 'registration' named 'bobo' exists + Given I am an administrator And a 'data_bag' named 'users' exists And a 'data_bag_item' named 'francis' exists And I wait for '15' seconds @@ -26,7 +26,7 @@ Feature: Search data via the REST API And the inflated responses key 'total' should be the integer '1' Scenario: Search for objects when two have been created - Given a 'registration' named 'bobo' exists + Given I am an administrator And a 'data_bag' named 'users' exists And a 'data_bag_item' named 'francis' exists And a 'data_bag_item' named 'axl_rose' exists @@ -41,7 +41,7 @@ Feature: Search data via the REST API And the inflated responses key 'total' should be the integer '2' Scenario: Search for objects with a manual ascending sort order - Given a 'registration' named 'bobo' exists + Given I am an administrator And a 'data_bag' named 'users' exists And a 'data_bag_item' named 'francis' exists And a 'data_bag_item' named 'axl_rose' exists @@ -56,7 +56,7 @@ Feature: Search data via the REST API And the inflated responses key 'total' should be the integer '2' Scenario: Search for objects with a manual descending sort order - Given a 'registration' named 'bobo' exists + Given I am an administrator And a 'data_bag' named 'users' exists And a 'data_bag_item' named 'francis' exists And a 'data_bag_item' named 'axl_rose' exists @@ -71,7 +71,7 @@ Feature: Search data via the REST API And the inflated responses key 'total' should be the integer '2' Scenario: Search for objects and page through the results - Given a 'registration' named 'bobo' exists + Given I am an administrator And a 'data_bag' named 'users' exists And a 'data_bag_item' named 'francis' exists And a 'data_bag_item' named 'axl_rose' exists @@ -91,7 +91,7 @@ Feature: Search data via the REST API And the inflated responses key 'total' should be the integer '2' Scenario: Search for a subset of objects - Given a 'registration' named 'bobo' exists + Given I am an administrator And a 'data_bag' named 'users' exists And a 'data_bag_item' named 'francis' exists And a 'data_bag_item' named 'axl_rose' exists @@ -104,7 +104,7 @@ Feature: Search data via the REST API And the inflated responses key 'total' should be the integer '1' Scenario: Search for a node - Given a 'registration' named 'bobo' exists + Given I am an administrator And a 'node' named 'searchman' exists And I wait for '15' seconds When I authenticate as 'bobo' @@ -115,7 +115,7 @@ Feature: Search data via the REST API And the inflated responses key 'rows' item '0' key 'walking' should be 'tall' Scenario: Search for a type of object that does not exist - Given a 'registration' named 'bobo' exists + Given I am an administrator When I authenticate as 'bobo' And I 'GET' the path '/search/funkensteins' Then I should get a '404 "Not Found"' exception |