FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
validators/tests/test_extremes.py at master · pythonthings/validators · GitHub
pythonthings
validators
Repository navigation
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
validators
/
tests
/
test_extremes.py
Copy path
More file actions
More file actions
Latest commit
History
History
History
45 lines (32 loc) · 814 Bytes
Breadcrumbs
validators
/
tests
/
test_extremes.py
Copy path
File metadata and controls
45 lines (32 loc) · 814 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# -*- coding: utf-8 -*-
import
pytest
from
validators
import
Max
,
Min
@
pytest
.
mark
.
parametrize
((
'value'
,), [
(
None
,),
(
''
,),
(
12
,),
(
Min
,),
])
def
test_max_is_greater_than_every_other_value
(
value
):
assert
value
<
Max
assert
Max
>
value
def
test_max_is_not_greater_than_itself
():
assert
not
(
Max
<
Max
)
def
test_other_comparison_methods_for_max
():
assert
Max
<=
Max
assert
Max
==
Max
assert
not
(
Max
!=
Max
)
@
pytest
.
mark
.
parametrize
((
'value'
,), [
(
None
,),
(
''
,),
(
12
,),
(
Max
,),
])
def
test_min_is_smaller_than_every_other_value
(
value
):
assert
value
>
Min
def
test_min_is_not_greater_than_itself
():
assert
not
(
Min
<
Min
)
def
test_other_comparison_methods_for_min
():
assert
Min
<=
Min
assert
Min
==
Min
assert
not
(
Min
!=
Min
)
Back
|
FazBrowse Home
|
New Git URL