Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5_fork
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Eteri
erp5_fork
Commits
99c8071f
Commit
99c8071f
authored
May 02, 2012
by
Sebastien Robin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix testAuthenticationPolicy random failures
parent
c40daab2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
product/ERP5/tests/testAuthenticationPolicy.py
product/ERP5/tests/testAuthenticationPolicy.py
+5
-0
No files found.
product/ERP5/tests/testAuthenticationPolicy.py
View file @
99c8071f
...
@@ -317,6 +317,11 @@ class TestAuthenticationPolicy(ERP5TypeTestCase):
...
@@ -317,6 +317,11 @@ class TestAuthenticationPolicy(ERP5TypeTestCase):
self
.
assertRaises
(
ValueError
,
person
.
setPassword
,
'12345678-new'
)
self
.
assertRaises
(
ValueError
,
person
.
setPassword
,
'12345678-new'
)
self
.
assertTrue
(
person
.
isPasswordValid
(
'12345678_'
))
# it's OK with another one not used yet
self
.
assertTrue
(
person
.
isPasswordValid
(
'12345678_'
))
# it's OK with another one not used yet
for
password
in
[
'a'
,
'b'
,
'c'
,
'd'
,
'e'
,
'f'
]:
for
password
in
[
'a'
,
'b'
,
'c'
,
'd'
,
'e'
,
'f'
]:
# this sleep is not so beautiful, but mysql datetime columns has a
# precision of one second only, and we use creation_date to order
# "Password Event" objects. So without this sleep, the test is
# failing randomly.
time
.
sleep
(
1
)
person
.
setPassword
(
password
)
person
.
setPassword
(
password
)
self
.
stepTic
()
self
.
stepTic
()
self
.
_clearCache
()
self
.
_clearCache
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment