Skip to content

Commit

Permalink
SWI-5458 Update Call Cleanup and Test WF (#139)
Browse files Browse the repository at this point in the history
* SWI-5458 Update Call Cleanup and Test WF

* remove spaces

* move allow

* move again

* spaces

* why is this not updating

* is it updating

* check out the right branch 🤦
  • Loading branch information
ckoegel authored Jun 19, 2024
1 parent 5c25a49 commit 15d91f9
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
name: Nightly Smoke Tests
name: Smoke Test

on:
schedule:
- cron: "0 4 * * *"
pull_request:
branches:
- main
paths:
- "spec/smoke/*"

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
Expand All @@ -26,13 +31,11 @@ env:

jobs:
test_main:
name: Nightly Smoke Test
name: Smoke Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: "main"

- name: Set up Ruby
uses: ruby/setup-ruby@v1
Expand Down
2 changes: 1 addition & 1 deletion spec/call_utils.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Helper functions for voice calls
# Helper functions for voice calls
# These are reused in multiple tests

def setup_manteca(type)
Expand Down
2 changes: 1 addition & 1 deletion spec/smoke/calls_api_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@

# Update Call
describe 'update_call' do
it 'creates and updates a call' do
it 'creates and updates a call' do
update_call_body = Bandwidth::UpdateCall.new(
state: Bandwidth::CallStateEnum::ACTIVE,
redirect_url: MANTECA_BASE_URL + '/bxml/pause'
Expand Down
4 changes: 3 additions & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
else
!(['/models/call_state_enum.rb',
'/models/call_state.rb',
'/models/deferred_result.rb',
'/models/deferred_result.rb',
'/models/message.rb',
'/models/verify_code_request.rb'
].any? { |name| source_file.filename.include?(name) })
Expand Down Expand Up @@ -89,7 +89,9 @@
config.password = BW_PASSWORD
end
calls_api = Bandwidth::CallsApi.new
WebMock.allow_net_connect!
cleanup_calls($active_calls, calls_api)
WebMock.disable_net_connect!
}

# rspec-expectations config goes here. You can use an alternate
Expand Down
4 changes: 2 additions & 2 deletions spec/unit/client/api_client_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -369,8 +369,8 @@
expect(api_client_default.build_collection_param(param, :tsv)).to eq("aa\tbb\tcc")
expect(api_client_default.build_collection_param(param, :pipes)).to eq('aa|bb|cc')
expect(api_client_default.build_collection_param(param, :multi)).to eq(['aa', 'bb', 'cc'])
expect {
api_client_default.build_collection_param(param, :INVALID)
expect {
api_client_default.build_collection_param(param, :INVALID)
}.to raise_error(RuntimeError, 'unknown collection format: :INVALID')
end
end
Expand Down

0 comments on commit 15d91f9

Please sign in to comment.