Skip to content

Commit

Permalink
Bump swagger and add tests
Browse files Browse the repository at this point in the history
  • Loading branch information
zhouzhuojie committed Dec 2, 2019
1 parent 7518a10 commit 0987e66
Show file tree
Hide file tree
Showing 49 changed files with 370 additions and 97 deletions.
3 changes: 2 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,5 @@ jobs:
steps:
- checkout
- run: go get -v -t -d ./...
- run: go build -v ./...
- run: make build
- run: make test
2 changes: 1 addition & 1 deletion .swagger-codegen/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.4.4
2.4.10
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,15 @@ gen:
rm -rf docs
rm -rf api
rm README.md
docker run --rm -v ${PWD}:/local swaggerapi/swagger-codegen-cli:2.4.4 generate \
docker run --rm -v ${PWD}:/local swaggerapi/swagger-codegen-cli:2.4.10 generate \
-i /local/swagger.yaml \
-l go \
-o /local/ -c /local/swagger_go.json
go get golang.org/x/tools/cmd/goimports
goimports -w .

test:
go test -race -covermode=atomic ./tests/...

build:
go build -v ./...
10 changes: 8 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Flagr is a feature flagging, A/B testing and dynamic configuration microservice.
## Overview
This API client was generated by the [swagger-codegen](https://github.com/swagger-api/swagger-codegen) project. By using the [swagger-spec](https://github.com/swagger-api/swagger-spec) from a remote server, you can easily generate an API client.

- API version: 1.1.0
- API version: 1.1.4
- Package version: 1.1.1
- Build package: io.swagger.codegen.languages.GoClientCodegen

Expand All @@ -29,7 +29,8 @@ Class | Method | HTTP request | Description
*DistributionApi* | [**PutDistributions**](docs/DistributionApi.md#putdistributions) | **Put** /flags/{flagID}/segments/{segmentID}/distributions |
*EvaluationApi* | [**PostEvaluation**](docs/EvaluationApi.md#postevaluation) | **Post** /evaluation |
*EvaluationApi* | [**PostEvaluationBatch**](docs/EvaluationApi.md#postevaluationbatch) | **Post** /evaluation/batch |
*ExportApi* | [**GetExportSQLite**](docs/ExportApi.md#getexportsqlite) | **Get** /export/sqlite |
*ExportApi* | [**GetExportEvalCacheJSON**](docs/ExportApi.md#getexportevalcachejson) | **Get** /export/eval_cache/json |
*ExportApi* | [**GetExportSqlite**](docs/ExportApi.md#getexportsqlite) | **Get** /export/sqlite |
*FlagApi* | [**CreateFlag**](docs/FlagApi.md#createflag) | **Post** /flags |
*FlagApi* | [**DeleteFlag**](docs/FlagApi.md#deleteflag) | **Delete** /flags/{flagID} |
*FlagApi* | [**FindFlags**](docs/FlagApi.md#findflags) | **Get** /flags |
Expand Down Expand Up @@ -66,6 +67,7 @@ Class | Method | HTTP request | Description
- [EvaluationEntity](docs/EvaluationEntity.md)
- [Flag](docs/Flag.md)
- [FlagSnapshot](docs/FlagSnapshot.md)
- [Health](docs/Health.md)
- [ModelError](docs/ModelError.md)
- [PutDistributionsRequest](docs/PutDistributionsRequest.md)
- [PutFlagRequest](docs/PutFlagRequest.md)
Expand All @@ -81,4 +83,8 @@ Class | Method | HTTP request | Description
## Documentation For Authorization
Endpoints do not require authorization.


## Author



Loading

0 comments on commit 0987e66

Please sign in to comment.