Skip to content

Commit

Permalink
entries: added time entries feature description & test implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
phiros committed Apr 15, 2019
1 parent 3402b6b commit 13ffb71
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions tests/features/entries.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
Feature: entries
In order to use mite in a sane manner
As a mite user
I need to be able to add, remove, edit and list time entries

Scenario: list entries
Given A local mock server is setup for the http method "GET" and path "/time_entries.json" which returns:
"""
[
{
"time_entry": {
"id": 36159117,
"minutes": 15,
"date_at": "2015-10-16",
"note": "Feedback einarbeiten",
"billable": true,
"locked": false,
"revenue": null,
"hourly_rate": 0,
"user_id": 211,
"user_name": "Fridolin Frei",
"project_id": 88309,
"project_name": "API v2",
"customer_id": 3213,
"customer_name": "König",
"service_id": 12984,
"service_name": "Entwurf",
"created_at": "2015-10-16T12:39:00+02:00",
"updated_at": "2015-10-16T12:39:00+02:00"
}
}
]
"""
And Mite is setup to connect to this mock server
Then "-c .mite.toml entries" should return the following:
"""
id notes date time project service
-- ----- ---- ---- ------- -------
36159117 Feedback einarbeiten 2015-10-16 15m API v2 Entwurf
"""

0 comments on commit 13ffb71

Please sign in to comment.