Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tsoc
openmm
Commits
00d20bd7
Commit
00d20bd7
authored
Jun 23, 2015
by
Jason Swails
Browse files
Use simpler string comparison (one that won't change from machine to machine due
to precision)
parent
10daac87
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
wrappers/python/tests/TestUnits.py
wrappers/python/tests/TestUnits.py
+1
-1
No files found.
wrappers/python/tests/TestUnits.py
View file @
00d20bd7
...
@@ -448,7 +448,7 @@ class TestUnits(QuantityTestCase):
...
@@ -448,7 +448,7 @@ class TestUnits(QuantityTestCase):
self
.
assertAlmostEqualQuantities
(
n
,
2.05834818672e-17
*
u
.
mole
)
self
.
assertAlmostEqualQuantities
(
n
,
2.05834818672e-17
*
u
.
mole
)
self
.
assertAlmostEqualQuantities
(
V
,
5.2359833333333e-19
*
u
.
meters
**
3
)
self
.
assertAlmostEqualQuantities
(
V
,
5.2359833333333e-19
*
u
.
meters
**
3
)
self
.
assertEqual
(
str
(
T
),
'310.0 K'
)
self
.
assertEqual
(
str
(
T
),
'310.0 K'
)
self
.
assertEqual
(
str
(
u
.
MOLAR_GAS_CONSTANT_R
),
'8.31447247122
J/(K mol)'
)
self
.
assertEqual
(
str
(
1
*
u
.
joules
/
u
.
kelvin
/
u
.
mole
),
'1
J/(K mol)'
)
self
.
assertTrue
(
u
.
is_quantity
(
V
))
self
.
assertTrue
(
u
.
is_quantity
(
V
))
# Checks trouble with complicated unit conversion factors
# Checks trouble with complicated unit conversion factors
p1
=
1.0
*
u
.
atmospheres
p1
=
1.0
*
u
.
atmospheres
...
...
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