Skip to content

Commit c9fa260

Browse files
authored
Autogenerate the SDK from the OpenAPI spec (#97)
* Implement the entire ShipEngine API via OpenAPI autogeneration using custom modified templates
1 parent 3b1e22a commit c9fa260

File tree

561 files changed

+73355
-15241
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

561 files changed

+73355
-15241
lines changed

.github/workflows/ci-cd.yaml

+6-6
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
run: msbuild shipengine-dotnet.sln /p:Configuration=Release
3333

3434
- name: Run Test
35-
run: dotnet test ShipEngine.Tests/bin/Release/net462/ShipEngine.Tests.dll
35+
run: dotnet test ShipEngineSDK.Test/bin/Release/net462/ShipEngineSDK.Test.dll
3636

3737
dot_net_core_test:
3838
name: .Net 8.0 on ${{ matrix.os }}
@@ -65,21 +65,21 @@ jobs:
6565
run: dotnet build --configuration Release
6666

6767
- name: Run 8.0 Tests
68-
run: dotnet test -f net8.0 --settings ShipEngine.Tests/coverage.runsettings
68+
run: dotnet test -f net8.0 --settings ShipEngineSDK.Test/coverage.runsettings
6969

7070
- name: Move generated lcov file to expected location
7171
shell: bash
7272
run: |
73-
ls -Rlh ShipEngine.Tests/TestResults/*/coverage.info
74-
cat ShipEngine.Tests/TestResults/*/coverage.info > ShipEngine.Tests/TestResults/lcov.info
73+
ls -Rlh ShipEngineSDK.Test/TestResults/*/coverage.info
74+
cat ShipEngineSDK.Test/TestResults/*/coverage.info > ShipEngineSDK.Test/TestResults/lcov.info
7575
7676
- name: Send code coverage results to Coveralls
7777
uses: coverallsapp/github-action@v1.1.0
7878
with:
7979
github-token: ${{ secrets.GITHUB_TOKEN }}
8080
parallel: true
8181
flag-name: run-${{ matrix.test_number }}
82-
path-to-lcov: ShipEngine.Tests/TestResults/lcov.info
82+
path-to-lcov: ShipEngineSDK.Test/TestResults/lcov.info
8383

8484
coverage:
8585
name: Code Coverage
@@ -112,7 +112,7 @@ jobs:
112112

113113
with:
114114
# Filepath of the project to be packaged, relative to root of repository
115-
PROJECT_FILE_PATH: ShipEngine/ShipEngine.csproj
115+
PROJECT_FILE_PATH: ShipEngineSDK/ShipEngineSDK.csproj
116116

117117
# NuGet package id, used for version detection & defaults to project name
118118
PACKAGE_NAME: ShipEngine

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,6 @@ TestResults
1616
.gitmodules
1717
dockerfile
1818
docker-compose.*
19+
20+
node_modules
21+
out

.openapi-generator-ignore

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# OpenAPI Generator Ignore
2+
# Generated by openapi-generator https://github.com/openapitools/openapi-generator
3+
4+
# Use this file to prevent files from being overwritten by the generator.
5+
# The patterns follow closely to .gitignore or .dockerignore.
6+
7+
# As an example, the C# client generator defines ApiClient.cs.
8+
# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line:
9+
#ApiClient.cs
10+
11+
# You can match any string of characters against a directory, file or extension with a single asterisk (*):
12+
#foo/*/qux
13+
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux
14+
15+
# You can recursively match patterns against a directory, file or extension with a double asterisk (**):
16+
#foo/**/qux
17+
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux
18+
19+
# You can also negate patterns with an exclamation (!).
20+
# For example, you can ignore all files in a docs folder with the file extension .md:
21+
#docs/*.md
22+
# Then explicitly reverse the ignore rule for a single file:
23+
#!docs/README.md
24+
25+
*.sln
26+
**/*.csproj
27+
appveyor.yml
28+
git_push.sh
29+
ShipEngineSDK/Client/*.cs
30+
31+
# We should re-enable these eventually
32+
README.md
33+
docs/*.md
34+
ShipEngineSDK.Test/*/*.cs
35+
api/**
36+
.gitignore
37+
.openapi-generator-ignore

0 commit comments

Comments
 (0)