Skip to content

Commit 3699634

Browse files
committed
Add feature tests for user keys listing.
1 parent 7c8044e commit 3699634

3 files changed

Lines changed: 182 additions & 0 deletions

File tree

features/cassettes/users/keys/user.yml

Lines changed: 64 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

features/cassettes/users/keys/user_all.yml

Lines changed: 91 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

features/users/keys.feature

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
Feature: Accessing Users Keys API
2+
3+
In order to interact with github user keys
4+
GithubAPI gem
5+
Should return the expected results depending on passed parameters
6+
7+
Background:
8+
Given I have "Github::Users::Keys" instance
9+
10+
Scenario: Lists all public keys for a user
11+
12+
Given I want to list resources
13+
And I pass the following request options:
14+
| user |
15+
| wycats |
16+
When I make request within a cassette named "users/keys/user_all"
17+
Then the response status should be 200
18+
And the response type should be JSON
19+
And the response should not be empty
20+
21+
Scenario: Lists all public keys for the authenticted user
22+
23+
Given I want to list resources
24+
When I make request within a cassette named "users/keys/user"
25+
Then the response status should be 200
26+
And the response type should be JSON
27+
And the response should be empty

0 commit comments

Comments
 (0)