preCICE
v3.2.0
Toggle main menu visibility
Main Page
Related Pages
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
Functions
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
Variables
_
a
b
c
d
e
f
h
i
m
n
p
r
s
t
Typedefs
b
d
e
g
l
m
p
r
s
t
u
v
Enumerations
Enumerator
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
~
Functions
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
~
Variables
_
a
b
c
d
e
f
g
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Typedefs
a
b
c
d
e
f
i
k
m
n
o
p
r
s
t
v
w
Enumerations
Enumerator
c
d
e
i
l
m
n
o
r
s
u
v
w
Related Symbols
Files
File List
File Members
All
_
a
b
c
d
e
g
i
j
m
n
o
p
r
s
t
v
Functions
a
b
c
g
m
p
r
s
t
v
Variables
Typedefs
Macros
b
d
m
n
p
t
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
Loading...
Searching...
No Matches
src
utils
tests
HashTest.cpp
Go to the documentation of this file.
1
#include "
testing/Testing.hpp
"
2
#include "
utils/Hash.hpp
"
3
4
BOOST_AUTO_TEST_SUITE
(UtilsTests)
5
BOOST_AUTO_TEST_SUITE
(HashTests)
6
7
PRECICE_TEST_SETUP
(1_rank)
8
BOOST_AUTO_TEST_CASE
(Empty)
9
{
10
PRECICE_TEST
();
11
BOOST_TEST(
precice::utils::preciceHash
(
""
) ==
"4d572a0ba37b5812b95a6e7b87898eea"
);
12
}
8
BOOST_AUTO_TEST_CASE
(Empty) {
…
}
13
14
PRECICE_TEST_SETUP
(1_rank)
15
BOOST_AUTO_TEST_CASE
(Letter)
16
{
17
PRECICE_TEST
();
18
BOOST_TEST(
precice::utils::preciceHash
(
"A"
) ==
"28c1219289105e64885266336db22f68"
);
19
}
15
BOOST_AUTO_TEST_CASE
(Letter) {
…
}
20
21
PRECICE_TEST_SETUP
(1_rank)
22
BOOST_AUTO_TEST_CASE
(Digit)
23
{
24
PRECICE_TEST
();
25
BOOST_TEST(
precice::utils::preciceHash
(
"1"
) ==
"cecd78530a875345828b93a514cb61c1"
);
26
}
22
BOOST_AUTO_TEST_CASE
(Digit) {
…
}
27
28
PRECICE_TEST_SETUP
(1_rank)
29
BOOST_AUTO_TEST_CASE
(XMLTags)
30
{
31
PRECICE_TEST
();
32
BOOST_TEST(
precice::utils::preciceHash
(
"<precice-configuration></precice-configuration>"
) ==
"ea6c463e64ba52f7b887e18452156fe6"
);
33
}
29
BOOST_AUTO_TEST_CASE
(XMLTags) {
…
}
34
35
BOOST_AUTO_TEST_SUITE_END
()
36
BOOST_AUTO_TEST_SUITE_END
()
BOOST_AUTO_TEST_CASE
BOOST_AUTO_TEST_CASE(Empty)
Definition
HashTest.cpp:8
Hash.hpp
BOOST_AUTO_TEST_SUITE
BOOST_AUTO_TEST_SUITE(PreProcess)
BOOST_AUTO_TEST_SUITE_END
BOOST_AUTO_TEST_SUITE_END()
Testing.hpp
PRECICE_TEST
#define PRECICE_TEST()
Definition
Testing.hpp:39
PRECICE_TEST_SETUP
#define PRECICE_TEST_SETUP(...)
Creates and attaches a TestSetup to a Boost test case.
Definition
Testing.hpp:29
precice::utils::preciceHash
std::string preciceHash(std::string_view s)
creates a portable hash of the given input
Definition
Hash.cpp:10