-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implemented deleting tickets feature
- Loading branch information
Showing
3 changed files
with
24 additions
and
0 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
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,7 @@ | ||
<div id='ticket'> | ||
<h2><%= @ticket.title %></h2> | ||
<%= link_to "Edit Ticket", [:edit, @project, @ticket] %> | ||
<%= link_to "Delete Ticket", [@project, @ticket], :method => :delete, | ||
:confirm => "Are you sure you want to delete this ticket?" %> | ||
<%= simple_format(@ticket.description) %> | ||
</div> |
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,16 @@ | ||
Feature: Deleting tickets | ||
In order to remove tickets | ||
As a user I want to press a button and make them disappear | ||
Background: | ||
Given there is a project called "TextMate 2" | ||
And that project has a ticket: | ||
| title | description | | ||
| Make it shiny! | Gradients! Starbursts! Oh my! | | ||
Given I am on the homepage | ||
When I follow "TextMate 2" | ||
And I follow "Make it shiny!" | ||
|
||
Scenario: Deleting a ticket | ||
When I follow "Delete Ticket" | ||
Then I should see "Ticket has been deleted." | ||
And I should be on the project page for "TextMate 2" |