-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add `/list numbered` and `/list rm <number>`
- Loading branch information
1 parent
d9b3fa5
commit 48a5435
Showing
7 changed files
with
184 additions
and
38 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
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
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 |
---|---|---|
@@ -0,0 +1,70 @@ | ||
Feature: List transactions | ||
|
||
Scenario: List | ||
Given I have a bot | ||
When I send the message "/deleteAll yes" | ||
And I wait 0.2 seconds | ||
When I send the message "/list" | ||
Then 1 messages should be sent back | ||
And the response should include the message "You might also be looking for archived transactions using '/list archived'." | ||
When I create a simple tx with amount 1.23 and accFrom someFromAccount and accTo someToAccount and desc Test Tx | ||
And I wait 0.1 seconds | ||
When I send the message "/list" | ||
Then 1 messages should be sent back | ||
And the response should include the message "-1.23 EUR" | ||
When I send the message "/archiveAll" | ||
And I wait 0.2 seconds | ||
And I send the message "/list" | ||
Then 1 messages should be sent back | ||
And the response should include the message "You might also be looking for archived transactions using '/list archived'." | ||
|
||
Scenario: List dated | ||
Given I have a bot | ||
When I send the message "/deleteAll yes" | ||
And I wait 0.2 seconds | ||
And I create a simple tx with amount 1.23 and accFrom someFromAccount and accTo someToAccount and desc Test Tx | ||
And I wait 0.1 seconds | ||
When I send the message "/list dated" | ||
Then 1 messages should be sent back | ||
And the response should include the message "; recorded on $today " | ||
|
||
Scenario: List archived | ||
Given I have a bot | ||
When I send the message "/deleteAll yes" | ||
And I wait 0.2 seconds | ||
When I send the message "/list archived" | ||
Then 1 messages should be sent back | ||
And the response should include the message "You might also be looking for transactions using '/list'." | ||
When I create a simple tx with amount 1.23 and accFrom someFromAccount and accTo someToAccount and desc Test Tx | ||
And I wait 0.1 seconds | ||
When I send the message "/list archived" | ||
Then 1 messages should be sent back | ||
And the response should include the message "You might also be looking for transactions using '/list'." | ||
When I send the message "/archiveAll" | ||
And I wait 0.2 seconds | ||
And I send the message "/list archived" | ||
Then 1 messages should be sent back | ||
And the response should include the message "-1.23 EUR" | ||
|
||
Scenario: List numbered | ||
Given I have a bot | ||
When I send the message "/deleteAll yes" | ||
And I wait 0.2 seconds | ||
And I create a simple tx with amount 1.23 and accFrom someFromAccount and accTo someToAccount and desc Test Tx | ||
And I wait 0.1 seconds | ||
And I create a simple tx with amount 1.23 and accFrom someFromAccount and accTo someToAccount and desc Another tx | ||
And I wait 0.1 seconds | ||
When I send the message "/list numbered" | ||
Then 1 messages should be sent back | ||
And the response should include the message "1) $today * "Test Tx"" | ||
And the same response should include the message "2) $today * "Another tx"" | ||
When I send the message "/list rm 1" | ||
Then 1 messages should be sent back | ||
And the response should include the message "Successfully deleted the list entry specified" | ||
When I send the message "/list numbered" | ||
And I wait 0.1 seconds | ||
Then 1 messages should be sent back | ||
And the response should include the message "1) $today * "Another tx"" | ||
When I send the message "/list rm 15" | ||
Then 1 messages should be sent back | ||
And the response should include the message "the number you specified was too high" |
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