Skip to content

Commit 996509f

Browse files
juliajanuajrice6713ckoegel
authored
SWI-4079: Merging feature branch with main! (#91)
* Remove all previous SDK remnants * Add bandwidth.json spec * Generate SDK using Openapi Generator CLI ```openapi-generator-cli generate -g csharp-netcore -i bandwidth.json -c openapi-config.yml``` * Add empty integration test files * add .vscode to gitignore * Remove vscode files * SWI-1670: Refactoring .NET Verbs (#69) * SWI-1645: adding Root BXML verbs * SWI-1645: Update test file name * SWI-1645: Update test file name one more time * SWI-1645: Update versions of actions used in test workflow * SWI-1645: Update runner version * SWI-1645: Update action versions in deploy action * SWI-1670: Revert changes to old BXML * SWI-1670: Updated serialization library used * SWI-1670: Adding new Verbs * SWI-1670: Updating gitignore * SWI-1670: Updating verbs * SWI-1670: Update Conference file to be uppercase * Update .github/workflows/deploy.yml Co-authored-by: AJ Rice <53190766+ajrice6713@users.noreply.github.com> * SWI-1670: Fixing comments and adding getters and setters where they were missing --------- Co-authored-by: AJ Rice <53190766+ajrice6713@users.noreply.github.com> * SWI-3245: Write Tests for the BXML Verbs (#70) * SWI-3245: Adding test files for verbs * SWI-3245: Adding test files for verbs for real * SWI-3245: all tests are written * SWI-3245: Adding DS_store to gitignore * SWI-3245: Add missing package * SWI-3245: Update netcore framework version used * SWI-3245: Fixing tests * SWI-3245: Updating tests again * SWI-3245: Update tests * SWI-3245: Add space to expected string for verbs with no attributes & context * SWI-3245: Update Tests to Target .NET 6 & 7 * SWI-1687: [.NET] Unit Tests for API Models (#71) * SWI-1687: Updating OpenAPI generated tests * SW-1687: finished up tests * SWI-1687: Formatting changes * SWI:1687: Update config files * SWI-1687: Remove additionalProperties tag in config file * Update openapi-config.yml Co-authored-by: Cameron Koegel <53310569+ckoegel@users.noreply.github.com> * SWI-1687: I wanted it in alphabetical order --------- Co-authored-by: Cameron Koegel <53310569+ckoegel@users.noreply.github.com> * SWI-3341: Update to OpenAPI Generator 7.0.0 (#72) * SWI-3342: generated with newest API spec file and added a new test (#73) * SWI-1680: [.NET] Unit Tests for APIs (#74) * SWI-3342: generated with newest API spec file and added a new test * SWI-1680: Added API Unit tests * SWI-1680: Update Test csproj file * SWI-1680: Trying to fix tests with streams * SWI-1632: [.NET] API Integration Tests (#75) * SWI-1632: Working on API integration tests * SWI-1632: Finished integration tests * SWI-1632: Added environment variables to workflows * SWI-1632: Added forbidden user & pass to workflows * SWI-1632: Added rate limit test * SWI-1632: Updating request to number * SWI-1632: Trying to get media tests to work * SWI-1632: General reformatting * SWI-1694: Update test and deployment workflows (#76) * SWI-1694: Updated test workflows * SWI-1694: Adding feature branch to nightly test * SWI-1694: Update deploy workflow * SWI-1694: Update deploy to handle pre-releases * SWI-1694: Update deployment workflow (#77) * SWI-1694: Updated test workflows * SWI-1694: Adding feature branch to nightly test * SWI-1694: Update deploy workflow * SWI-1694: Update deploy to handle pre-releases * SWI-1694: fix conditional statement * SWI-1694: Updated regex * SWI-1694: Update CODEOWNERS * SWI-1694: Updating echo command to be nicer * SWI-1695: updating the regex again (#78) * SWI-1695: Fix regex for new releases (#79) * SWI-1695: updating the regex again * SWI-1695: updating the regex again pt.2 * SWI-1695: removed comment * SWI-1695: Update quotes * SWI-1695: Adding a missing environment variable (#80) * SWI-1695: updating the regex again * SWI-1695: updating the regex again pt.2 * SWI-1695: removed comment * SWI-1695: Update quotes * SWI-1695: Add missing environment variable * Update deploy.yml * SWI-1695: Updated env vars * SWI-1696: Finishing touches before beta release (#81) * SWI-1696: Update csproj and openapi ignore files * Update src/Bandwidth.Standard/Bandwidth.Standard.csproj Co-authored-by: AJ Rice <53190766+ajrice6713@users.noreply.github.com> * Update src/Bandwidth.Standard/Bandwidth.Standard.csproj Co-authored-by: AJ Rice <53190766+ajrice6713@users.noreply.github.com> --------- Co-authored-by: AJ Rice <53190766+ajrice6713@users.noreply.github.com> * SWI-3915: Regenerate C# SDK and add tests for new endpoint (#82) * SWI-3915: Regenerated SDK & added tests for new endpoint * SWI-3915: Uncomment [Fact] * SWI-3915: Fix list calls api test * SWI-3933: Regenerated with version 7.1.0 (#83) * SWI-3945: Adding "update-sdk" workflow (#84) * SWI-3945: Add an update SDK workflow * Update .github/workflows/update-sdk.yml Co-authored-by: Cameron Koegel <53310569+ckoegel@users.noreply.github.com> --------- Co-authored-by: Cameron Koegel <53310569+ckoegel@users.noreply.github.com> * SWI-4077: Remove the update-sdk workflow (#90) --------- Co-authored-by: AJ Rice <53190766+ajrice6713@users.noreply.github.com> Co-authored-by: Cameron Koegel <53310569+ckoegel@users.noreply.github.com>
1 parent 8e57d54 commit 996509f

File tree

583 files changed

+84854
-25329
lines changed

Some content is hidden

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

583 files changed

+84854
-25329
lines changed

.github/CODEOWNERS

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
# Global rule:
2-
* @Bandwidth/dx
2+
* @Bandwidth/band-swi @Bandwidth/band-swi-github-repo-admin

.github/workflows/deploy.yml

+103-23
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,123 @@
1-
name: Deploy
1+
name: Deploy SDK
2+
23
on:
34
release:
45
types:
56
- published
7+
8+
env:
9+
BW_ACCOUNT_ID: ${{ secrets.BW_ACCOUNT_ID }}
10+
BW_USERNAME: ${{ secrets.BW_USERNAME }}
11+
BW_PASSWORD: ${{ secrets.BW_PASSWORD }}
12+
BW_USERNAME_FORBIDDEN: ${{ secrets.BW_USERNAME_FORBIDDEN}}
13+
BW_PASSWORD_FORBIDDEN: ${{ secrets.BW_PASSWORD_FORBIDDEN}}
14+
BW_VOICE_APPLICATION_ID: ${{ secrets.BW_VOICE_APPLICATION_ID }}
15+
BW_MESSAGING_APPLICATION_ID: ${{ secrets.BW_MESSAGING_APPLICATION_ID }}
16+
BW_NUMBER: ${{ secrets.BW_NUMBER }}
17+
USER_NUMBER: ${{ secrets.USER_NUMBER }}
18+
BASE_CALLBACK_URL: ${{ secrets.BASE_CALLBACK_URL }}
19+
MANTECA_ACTIVE_NUMBER: ${{ secrets.MANTECA_ACTIVE_NUMBER }}
20+
MANTECA_APPLICATION_ID: ${{ secrets.MANTECA_APPLICATION_ID }}
21+
MANTECA_BASE_URL: ${{ secrets.MANTECA_BASE_URL }}
22+
MANTECA_IDLE_NUMBER: ${{ secrets.MANTECA_IDLE_NUMBER }}
23+
OPERATING_SYSTEM: ubuntu-latest
24+
DOTNET_VERSION: 7.0.x
25+
626
jobs:
7-
publish:
8-
name: Publish
9-
if: ${{ !github.event.release.prerelease && github.event.release.target_commitish == 'main' }}
10-
env:
11-
BW_PROJECT_NAME: Bandwidth.Standard
12-
BW_PROJECT_TEST_NAME: Bandwidth.StandardTests
27+
deploy_pre_release:
28+
name: Deploy OpenAPI Generator Client Pre-Release
29+
if: ${{ github.event.release.prerelease && github.event.release.target_commitish == 'feature/openapi-generator-sdk' }}
1330
runs-on: ubuntu-latest
14-
steps:
15-
- uses: actions/checkout@v3
16-
31+
env:
32+
BW_PROJECT_NAME: src/Bandwidth.Standard
33+
BW_PROJECT_TEST_NAME: src/Bandwidth.Standard.Test
34+
steps:
1735
- name: Set release version
1836
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/v}" >> $GITHUB_ENV
37+
38+
- name: Check Release Tag Format
39+
run: |
40+
if ! [[ $RELEASE_VERSION =~ ^(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)(-(beta|alpha|rc))(\.[0-9][0-9]*)?$ ]]; then
41+
echo 'Tag does not match expected regex pattern for beta releases (^(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)(-(beta|alpha|rc))(\.[0-9][0-9]*)?$)'
42+
echo $RELEASE_VERSION
43+
echo 'Please update your tag to match the expected regex pattern'
44+
exit 1
45+
fi
46+
47+
- name: Checkout
48+
uses: actions/checkout@v3
49+
with:
50+
ref: feature/openapi-generator-sdk
1951

20-
- uses: actions/setup-dotnet@v3
52+
- name: Setup Dotnet
53+
uses: actions/setup-dotnet@v1
2154
with:
22-
dotnet-version: "6.0"
55+
dotnet-version: '7.0.x'
2356

24-
- name: Run integration tests
25-
env:
26-
BW_ACCOUNT_ID: ${{ secrets.BW_ACCOUNT_ID }}
27-
BW_USERNAME: ${{ secrets.BW_USERNAME }}
28-
BW_PASSWORD: ${{ secrets.BW_PASSWORD }}
29-
BW_VOICE_APPLICATION_ID: ${{ secrets.BW_VOICE_APPLICATION_ID }}
30-
BW_MESSAGING_APPLICATION_ID: ${{ secrets.BW_MESSAGING_APPLICATION_ID }}
31-
BW_NUMBER: ${{ secrets.BW_NUMBER }}
32-
USER_NUMBER: ${{ secrets.USER_NUMBER }}
33-
BASE_CALLBACK_URL: ${{ secrets.BASE_CALLBACK_URL }}
57+
- name: Run functional tests
3458
run: dotnet test $BW_PROJECT_TEST_NAME
35-
59+
3660
- name: Pack NuGet package
3761
run: dotnet pack --configuration Release $BW_PROJECT_NAME -p:PackageVersion=$RELEASE_VERSION
62+
63+
- name: Publish NuGet package
64+
env:
65+
NUGET_KEY: ${{ secrets.NUGET_KEY }}
66+
NUGET_SOURCE: https://api.nuget.org/v3/index.json
67+
run: dotnet nuget push $BW_PROJECT_NAME/bin/Release/*.nupkg -s $NUGET_SOURCE -k $NUGET_KEY
3868

69+
- name: Notify Slack of build status
70+
uses: Bandwidth/build-notify-slack-action@v1.0.0
71+
if: always()
72+
with:
73+
job-status: ${{ job.status }}
74+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
75+
slack-channel: ${{ secrets.SLACK_CHANNEL }}
76+
77+
deploy:
78+
name: deploy 'main' branch
79+
if: ${{ !github.event.release.prerelease && github.event.release.target_commitish == 'main' }}
80+
runs-on: ubuntu-latest
81+
env:
82+
BW_PROJECT_NAME: src/Bandwidth.Standard
83+
BW_PROJECT_TEST_NAME: src/Bandwidth.Standard.Test
84+
steps:
85+
- name: Set release version
86+
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/v}" >> $GITHUB_ENV
87+
88+
- name: Check Release Tag Format
89+
run: |
90+
if ! [[ $RELEASE_VERSION =~ ^(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)$ ]]; then
91+
echo 'Tag does not match expected regex pattern for releases (^(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)$)'
92+
echo $RELEASE_VERSION
93+
echo 'Please update your tag to match the expected regex pattern'
94+
exit 1
95+
fi
96+
97+
- name: Checkout
98+
uses: actions/checkout@v3
99+
100+
- name: Setup Dotnet
101+
uses: actions/setup-dotnet@v1
102+
with:
103+
dotnet-version: '7.0.x'
104+
105+
- name: Run functional tests
106+
run: dotnet test $BW_PROJECT_TEST_NAME
107+
108+
- name: Pack NuGet package
109+
run: dotnet pack --configuration Release $BW_PROJECT_NAME -p:PackageVersion=$RELEASE_VERSION
110+
39111
- name: Publish NuGet package
40112
env:
41113
NUGET_KEY: ${{ secrets.NUGET_KEY }}
42114
NUGET_SOURCE: https://api.nuget.org/v3/index.json
43115
run: dotnet nuget push $BW_PROJECT_NAME/bin/Release/*.nupkg -s $NUGET_SOURCE -k $NUGET_KEY
116+
117+
- name: Notify Slack of build status
118+
uses: Bandwidth/build-notify-slack-action@v1.0.0
119+
if: always()
120+
with:
121+
job-status: ${{ job.status }}
122+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
123+
slack-channel: ${{ secrets.SLACK_CHANNEL }}

.github/workflows/test-nightly.yml

+82
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
name: Test Main Branch Nightly
2+
on:
3+
schedule:
4+
- cron: "0 4 * * *"
5+
6+
env:
7+
BW_ACCOUNT_ID: ${{ secrets.BW_ACCOUNT_ID }}
8+
BW_USERNAME: ${{ secrets.BW_USERNAME }}
9+
BW_PASSWORD: ${{ secrets.BW_PASSWORD }}
10+
BW_USERNAME_FORBIDDEN: ${{ secrets.BW_USERNAME_FORBIDDEN}}
11+
BW_PASSWORD_FORBIDDEN: ${{ secrets.BW_PASSWORD_FORBIDDEN}}
12+
BW_VOICE_APPLICATION_ID: ${{ secrets.BW_VOICE_APPLICATION_ID }}
13+
BW_MESSAGING_APPLICATION_ID: ${{ secrets.BW_MESSAGING_APPLICATION_ID }}
14+
BW_NUMBER: ${{ secrets.BW_NUMBER }}
15+
USER_NUMBER: ${{ secrets.USER_NUMBER }}
16+
BASE_CALLBACK_URL: ${{ secrets.BASE_CALLBACK_URL }}
17+
MANTECA_ACTIVE_NUMBER: ${{ secrets.MANTECA_ACTIVE_NUMBER }}
18+
MANTECA_APPLICATION_ID: ${{ secrets.MANTECA_APPLICATION_ID }}
19+
MANTECA_BASE_URL: ${{ secrets.MANTECA_BASE_URL }}
20+
MANTECA_IDLE_NUMBER: ${{ secrets.MANTECA_IDLE_NUMBER }}
21+
22+
jobs:
23+
test_main:
24+
name: Test Main Branch Nightly
25+
runs-on: ${{ matrix.os }}
26+
strategy:
27+
matrix:
28+
os: [windows-2022, windows-2019, ubuntu-22.04, ubuntu-20.04]
29+
dotnet: [6.0.x, 7.0.x]
30+
steps:
31+
- name: Checkout repo
32+
uses: actions/checkout@v3
33+
with:
34+
ref: "main"
35+
36+
- name: Setup .NET
37+
uses: actions/setup-dotnet@v3
38+
with:
39+
dotnet-version: ${{ matrix.dotnet }}
40+
41+
- name: Run functional tests
42+
env:
43+
OPERATING_SYSTEM: ${{ matrix.os }}
44+
DOTNET_VERSION: ${{ matrix.dotnet }}
45+
run: dotnet test src/Bandwidth.Standard.Test
46+
47+
test_feature:
48+
name: Test Feature Branch Nightly
49+
runs-on: ${{ matrix.os }}
50+
strategy:
51+
matrix:
52+
os: [windows-2022, windows-2019, ubuntu-22.04, ubuntu-20.04]
53+
dotnet: [6.0.x, 7.0.x]
54+
steps:
55+
- name: Checkout repo
56+
uses: actions/checkout@v3
57+
with:
58+
ref: "feature/openapi-generator-sdk"
59+
60+
- name: Setup .NET
61+
uses: actions/setup-dotnet@v3
62+
with:
63+
dotnet-version: ${{ matrix.dotnet }}
64+
65+
- name: Run functional tests
66+
env:
67+
OPERATING_SYSTEM: ${{ matrix.os }}
68+
DOTNET_VERSION: ${{ matrix.dotnet }}
69+
run: dotnet test src/Bandwidth.Standard.Test
70+
71+
notify_for_failures:
72+
name: Notify for failures
73+
needs: [test_main, test_feature]
74+
if: failure()
75+
runs-on: ubuntu-latest
76+
steps:
77+
- name: Notify Slack of failures
78+
uses: Bandwidth/build-notify-slack-action@v1.0.0
79+
with:
80+
job-status: failure
81+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
82+
slack-channel: ${{ secrets.SLACK_CHANNEL }}

.github/workflows/test-pr.yml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Test PR
2+
on:
3+
pull_request:
4+
workflow_dispatch:
5+
6+
env:
7+
BW_ACCOUNT_ID: ${{ secrets.BW_ACCOUNT_ID }}
8+
BW_USERNAME: ${{ secrets.BW_USERNAME }}
9+
BW_PASSWORD: ${{ secrets.BW_PASSWORD }}
10+
BW_USERNAME_FORBIDDEN: ${{ secrets.BW_USERNAME_FORBIDDEN}}
11+
BW_PASSWORD_FORBIDDEN: ${{ secrets.BW_PASSWORD_FORBIDDEN}}
12+
BW_VOICE_APPLICATION_ID: ${{ secrets.BW_VOICE_APPLICATION_ID }}
13+
BW_MESSAGING_APPLICATION_ID: ${{ secrets.BW_MESSAGING_APPLICATION_ID }}
14+
BW_NUMBER: ${{ secrets.BW_NUMBER }}
15+
USER_NUMBER: ${{ secrets.USER_NUMBER }}
16+
BASE_CALLBACK_URL: ${{ secrets.BASE_CALLBACK_URL }}
17+
MANTECA_ACTIVE_NUMBER: ${{ secrets.MANTECA_ACTIVE_NUMBER }}
18+
MANTECA_APPLICATION_ID: ${{ secrets.MANTECA_APPLICATION_ID }}
19+
MANTECA_BASE_URL: ${{ secrets.MANTECA_BASE_URL }}
20+
MANTECA_IDLE_NUMBER: ${{ secrets.MANTECA_IDLE_NUMBER }}
21+
22+
jobs:
23+
test_pr:
24+
name: Test PR
25+
runs-on: ${{ matrix.os }}
26+
strategy:
27+
matrix:
28+
os: [windows-2022, windows-2019, ubuntu-22.04, ubuntu-20.04]
29+
dotnet: [6.0.x, 7.0.x]
30+
steps:
31+
- name: Checkout repo
32+
uses: actions/checkout@v3
33+
34+
- name: Setup .NET
35+
uses: actions/setup-dotnet@v3
36+
with:
37+
dotnet-version: ${{ matrix.dotnet }}
38+
39+
- name: Run functional tests
40+
env:
41+
OPERATING_SYSTEM: ${{ matrix.os }}
42+
DOTNET_VERSION: ${{ matrix.dotnet }}
43+
run: dotnet test src/Bandwidth.Standard.Test

.github/workflows/test.yml

-49
This file was deleted.

0 commit comments

Comments
 (0)