Skip to content

Commit

Permalink
Merge pull request Shopify#42 from agrberg/ar/ruby_3_update
Browse files Browse the repository at this point in the history
Ruby 3 update
  • Loading branch information
ltk authored Jan 10, 2022
2 parents 197230d + 1cb45ea commit 91dd415
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ The [API Test Client](https://developer.okta.com/docs/api/getting_started/api_te

## Contributing

1. Fork it ( <https://github.com/hopify/oktakit/fork> )
1. Fork it ( <https://github.com/shopify/oktakit/fork> )
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
Expand Down
4 changes: 2 additions & 2 deletions lib/oktakit.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
require 'oktakit/client'

module Oktakit
def self.new(*args)
Client.new(*args)
def self.new(**args)
Client.new(**args)
end
end
7 changes: 7 additions & 0 deletions spec/oktakit_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@
expect(Oktakit::VERSION).not_to(be(nil))
end

describe '.new' do
it 'creates a client with the passed in keyword arguments' do
client = Oktakit.new(token: test_okta_token, organization: 'okta-test')
expect(client.api_endpoint).to(eq('https://okta-test.okta.com/api/v1'))
end
end

describe 'client' do
it 'has a default API endpoint' do
client = Oktakit::Client.new(token: test_okta_token, organization: 'okta-test')
Expand Down

0 comments on commit 91dd415

Please sign in to comment.