Skip to content

Commit

Permalink
Try to stabilize the build
Browse files Browse the repository at this point in the history
  • Loading branch information
hzalaz committed Jun 1, 2015
1 parent 21c4b56 commit 9246424
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion spec/integration/lib/auth0/api/v1/api_users_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

let(:client) { Auth0Client.new(v1_creds) }
let(:username) { Faker::Internet.user_name }
let(:email) { Faker::Internet.safe_email("#{username}#{entity_suffix}") }
let(:email) { "#{entity_suffix}#{Faker::Internet.safe_email(user_name)}" }
let(:password) { Faker::Internet.password }
let(:connection) { "Username-Password-Authentication" }
let!(:user) { client.create_user(email, password, connection, {
Expand Down
2 changes: 1 addition & 1 deletion spec/integration/lib/auth0/api/v2/api_users_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

let(:client) { Auth0Client.new(v2_creds) }
let(:username) { Faker::Internet.user_name }
let(:email) { Faker::Internet.safe_email("#{username}#{entity_suffix}") }
let(:email) { "#{entity_suffix}#{Faker::Internet.safe_email(user_name)}" }
let(:password) { Faker::Internet.password }
let(:connection) { "Username-Password-Authentication" }
let!(:user) { client.create_user(username, {
Expand Down
2 changes: 2 additions & 0 deletions spec/spec_helper_full.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ def entity_suffix
config.include Rack::Test::Methods
config.include Credentials
config.after(:suite) do
puts "Cleaning up for #{entity_suffix}"
v2_client = Auth0Client.new({token: ENV["MASTER_JWT"], api_version: 2, domain: ENV["DOMAIN"]})
v2_client
.clients
Expand All @@ -38,5 +39,6 @@ def entity_suffix
.users
.select { |user| user["email"].split("@").first.include? entity_suffix }
.each { |user| v2_client.delete_user(user["user_id"])}
puts "Finished cleaning up for #{entity_suffix}"
end
end

0 comments on commit 9246424

Please sign in to comment.