Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
http_client_manager-3451503
Manage
Activity
Members
Labels
Plan
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Issue forks
http_client_manager-3451503
Commits
ad1ab19d
Commit
ad1ab19d
authored
7 years ago
by
Adriano Cori
Browse files
Options
Downloads
Patches
Plain Diff
updated service descriptions for tests
parent
db809f1b
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
tests/src/Unit/HttpClientTest.php
+2
-1
2 additions, 1 deletion
tests/src/Unit/HttpClientTest.php
tests/src/Unit/api/items/posts.json
+38
-2
38 additions, 2 deletions
tests/src/Unit/api/items/posts.json
tests/src/Unit/api/test_api.json
+1
-1
1 addition, 1 deletion
tests/src/Unit/api/test_api.json
with
41 additions
and
4 deletions
tests/src/Unit/HttpClientTest.php
+
2
−
1
View file @
ad1ab19d
...
...
@@ -129,7 +129,7 @@ class HttpClientTest extends UnitTestCase {
$this
->
assertInternalType
(
'array'
,
$result
);
$this
->
assertGreaterThan
(
1
,
count
(
$result
));
$result
=
$this
->
client
->
findPost
s
([
'postId'
=>
1
]);
$result
=
$this
->
client
->
findPost
([
'postId'
=>
1
]);
$this
->
assertNotEmpty
(
$result
);
$this
->
assertInternalType
(
'array'
,
$result
);
$this
->
assertArrayHasKey
(
'id'
,
$result
);
...
...
@@ -183,6 +183,7 @@ class HttpClientTest extends UnitTestCase {
*/
public
function
providerTestGetCommand
()
{
return
[
[
'FindPost'
],
[
'FindPosts'
],
[
'FindComments'
],
];
...
...
This diff is collapsed.
Click to expand it.
tests/src/Unit/api/items/posts.json
+
38
−
2
View file @
ad1ab19d
{
"operations"
:
{
"FindPosts"
:
{
"httpMethod"
:
"GET"
,
"uri"
:
"posts"
,
"summary"
:
"Find posts"
,
"responseClass"
:
"FindPostsOutput"
},
"FindPost"
:
{
"httpMethod"
:
"GET"
,
"uri"
:
"posts/{postId}"
,
"summary"
:
"Find posts"
,
"responseClass"
:
"Post"
,
"parameters"
:
{
"postId"
:
{
"location"
:
"uri"
,
"description"
:
"Filter posts by id"
,
"required"
:
fals
e
,
"required"
:
tru
e
,
"type"
:
"string"
}
}
...
...
@@ -27,5 +34,34 @@
}
}
},
"models"
:
{}
"models"
:
{
"Post"
:
{
"type"
:
"object"
,
"properties"
:
{
"userId"
:
{
"location"
:
"json"
,
"type"
:
"integer"
},
"id"
:
{
"location"
:
"json"
,
"type"
:
"integer"
},
"title"
:
{
"location"
:
"json"
,
"type"
:
"string"
},
"body"
:
{
"location"
:
"json"
,
"type"
:
"string"
}
}
},
"FindPostsOutput"
:
{
"location"
:
"json"
,
"type"
:
"array"
,
"items"
:
{
"$ref"
:
"Post"
}
}
}
}
This diff is collapsed.
Click to expand it.
tests/src/Unit/api/test_api.json
+
1
−
1
View file @
ad1ab19d
...
...
@@ -2,7 +2,7 @@
"name"
:
"TestApi"
,
"apiVersion"
:
"2016-07-29"
,
"description"
:
"Client wrapper for the TestApi API."
,
"i
nclude
s"
:
[
"i
mport
s"
:
[
"items/posts.json"
]
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment