Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
reminec
Limaju Server Symfony
Commits
3e8bbdf7
Commit
3e8bbdf7
authored
Oct 02, 2019
by
Dominique Merle
💬
Browse files
Add the step definition for deleting polls.
We'll need another step def for deleting polls using a password.
parent
48f46896
Changes
1
Hide whitespace changes
Inline
Side-by-side
features/bootstrap/ApiRestFeatureContext.php
View file @
3e8bbdf7
...
...
@@ -115,4 +115,19 @@ class ApiRestFeatureContext extends BaseFeatureContext
}
}
/**
* @When /^(?P<actor>.+?)(?P<try> (?:essa[iy]ez?|tente) de|) supprimer?(?: (?:de|à) nouveau)? le scrutin titré "(?P<title>.+)"$/ui
* @When /^(?P<actor>.+?)(?P<try> tr(?:y|ies) to|) deletes? the majority judgment poll titled "(?P<title>.+)"$/ui
*/
public
function
actorDeletesTheLimajuPollTitled
(
$actor
,
$try
,
$title
)
{
$poll
=
$this
->
findOneLimajuPollFromTitle
(
$title
);
$this
->
actor
(
$actor
)
->
api
(
'DELETE'
,
"/limaju_polls/"
.
$poll
->
getId
(),
[],
[],
!
empty
(
$try
)
);
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment