Skip to content

Commit fd6badf

Browse files
committed
add service proto to address CI failure
1 parent e957b2a commit fd6badf

5 files changed

Lines changed: 108 additions & 1 deletion

File tree

modules/openapi-generator/src/test/resources/3_0/protobuf/petstore-complex.yaml

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,37 @@ tags:
1717
description: Access to Petstore orders
1818
- name: user
1919
description: Operations about user
20-
paths: {}
20+
paths:
21+
/pets:
22+
get:
23+
requestBody:
24+
content:
25+
application/json:
26+
schema:
27+
$ref: "#/components/schemas/Cat"
28+
responses:
29+
"200":
30+
description: Updated
2131
externalDocs:
2232
description: Find out more about Swagger
2333
url: 'http://swagger.io'
2434
components:
2535
schemas:
36+
Dog:
37+
type: object
38+
properties:
39+
bark:
40+
type: boolean
41+
breed:
42+
type: string
43+
enum: [ Dingo, Husky, Retriever, Shepherd ]
44+
Cat:
45+
type: object
46+
properties:
47+
hunts:
48+
type: boolean
49+
age:
50+
type: integer
2651
Category:
2752
title: Pet category
2853
description: A category for a pet
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
README.md
2+
models/cat.proto
23
models/category.proto
4+
models/dog.proto
35
models/pet.proto
46
models/string_array.proto
57
models/string_map.proto
68
models/tag.proto
79
models/tag_name.proto
10+
services/default_service.proto
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/*
2+
OpenAPI Petstore
3+
4+
This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
5+
6+
The version of the OpenAPI document: 1.0.0
7+
8+
Generated by OpenAPI Generator: https://openapi-generator.tech
9+
*/
10+
11+
syntax = "proto3";
12+
13+
package petstore;
14+
15+
16+
message Cat {
17+
18+
bool hunts = 1;
19+
20+
int32 age = 2;
21+
22+
}
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
/*
2+
OpenAPI Petstore
3+
4+
This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
5+
6+
The version of the OpenAPI document: 1.0.0
7+
8+
Generated by OpenAPI Generator: https://openapi-generator.tech
9+
*/
10+
11+
syntax = "proto3";
12+
13+
package petstore;
14+
15+
16+
message Dog {
17+
18+
bool bark = 1;
19+
20+
enum Breed {
21+
BREED_UNSPECIFIED = 0;
22+
BREED_DINGO = 1;
23+
BREED_HUSKY = 2;
24+
BREED_RETRIEVER = 3;
25+
BREED_SHEPHERD = 4;
26+
}
27+
28+
Breed breed = 2;
29+
30+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/*
2+
OpenAPI Petstore
3+
4+
This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
5+
6+
The version of the OpenAPI document: 1.0.0
7+
8+
Generated by OpenAPI Generator: https://openapi-generator.tech
9+
*/
10+
11+
syntax = "proto3";
12+
13+
package petstore.services.defaultservice;
14+
15+
import "google/protobuf/empty.proto";
16+
import public "models/cat.proto";
17+
18+
service DefaultService {
19+
rpc PetsGet (PetsGetRequest) returns (google.protobuf.Empty);
20+
21+
}
22+
23+
message PetsGetRequest {
24+
Cat cat = 1;
25+
26+
}
27+

0 commit comments

Comments
 (0)