Skip to content

Commit 6a6e646

Browse files
authored
Add sleep after upserting user and changing password in change_password test (#70)
1 parent 0a530e7 commit 6a6e646

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

test/user_manager_test.rb

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ def setup
6363
sleep(0.01)
6464
next
6565
end
66+
sleep(0.1)
6667
return
6768
end
6869
raise "User could not be created"
@@ -86,6 +87,8 @@ def test_change_password
8687
new_password = "a_new_password"
8788
@cluster.users.change_password(new_password)
8889

90+
sleep(0.1)
91+
8992
# Verify that the connection fails with the old password
9093
assert_raises(Error::AuthenticationFailure) { Cluster.connect(@env.connection_string, orig_options) }
9194

@@ -97,6 +100,8 @@ def test_change_password
97100
# Change the password back to the original one
98101
@cluster.users.change_password(@test_password)
99102

103+
sleep(0.1)
104+
100105
# Verify that the connection fails with the new password
101106
assert_raises(Error::AuthenticationFailure) { Cluster.connect(@env.connection_string, new_options) }
102107
end

0 commit comments

Comments
 (0)