mirror of
https://github.com/TracksApp/tracks.git
synced 2026-01-26 18:56:10 +01:00
fix #1052 based on the work of Tim Madden. Thanks Tim!
This commit is contained in:
parent
e9d92438d6
commit
b53fbc64dc
8 changed files with 78 additions and 28 deletions
|
|
@ -24,6 +24,13 @@ Given /^I have a project called "([^"]*)"$/ do |project_name|
|
|||
Given "there exists a project \"#{project_name}\" for user \"#{@current_user.login}\""
|
||||
end
|
||||
|
||||
Given /^I have a project "([^"]*)" with a default context of "([^"]*)"$/ do |project_name, context_name|
|
||||
Given "there exists a project \"#{project_name}\" for user \"#{@current_user.login}\""
|
||||
context = @current_user.contexts.create!(:name => context_name)
|
||||
@project.default_context = context
|
||||
@project.save!
|
||||
end
|
||||
|
||||
Given /^I have the following projects:$/ do |table|
|
||||
table.hashes.each do |project|
|
||||
Given 'I have a project called "'+project[:project_name]+'"'
|
||||
|
|
@ -189,4 +196,4 @@ end
|
|||
|
||||
Then /^I should see the project name is "([^"]*)"$/ do |project_name|
|
||||
Then "the project title should be \"#{project_name}\""
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue