Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Added cukes to test the display of default actions in the index table

  • Loading branch information...
commit c80fd93e7f79e4c930d68d824e053f4d7fa74fa3 1 parent 82bd4c1
Greg Bell authored October 13, 2011
14  features/index/index_as_table.feature
@@ -79,3 +79,17 @@ Feature: Index as Table
79 79
     And I should not see a table header with "Body"
80 80
     And I should see "Hello World"
81 81
     And I should not see "From the body"
  82
+
  83
+  Scenario: Default Actions
  84
+    Given a post with the title "Hello World" and body "From the body" exists
  85
+    And an index configuration of:
  86
+      """
  87
+      ActiveAdmin.register Post do
  88
+        actions :index, :show, :edit, :update
  89
+      end
  90
+      """
  91
+    Then I should see a member link to "View"
  92
+    And I should see a member link to "Edit"
  93
+    And I should not see a member link to "Delete"
  94
+
  95
+
5  features/specifying_actions.feature
@@ -7,6 +7,11 @@ Feature: Specifying Actions
7 7
       """
8 8
         ActiveAdmin.register Post do
9 9
           actions :index
  10
+          index do
  11
+            column do |post|
  12
+              link_to "View", admin_post_path(post)
  13
+            end
  14
+          end
10 15
         end
11 16
       """
12 17
 	And I am logged in
7  features/step_definitions/action_link_steps.rb
... ...
@@ -0,0 +1,7 @@
0  features/step_definitions/action_item_steps.rb → features/step_definitions/member_link_steps.rb
File renamed without changes

0 notes on commit c80fd93

Please sign in to comment.
Something went wrong with that request. Please try again.