summaryrefslogtreecommitdiff
path: root/selftest.cpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2013-10-07 09:36:20 -0400
committerAdam Ierymenko <adam.ierymenko@gmail.com>2013-10-07 09:36:20 -0400
commit0c8614b9c6ff049a1005b713e65365a3394d461c (patch)
tree6336b93dae6ac1a9ab1629e3f8f93132218e083b /selftest.cpp
parent5fa7a920488badd48776e633a4cc941282dd9473 (diff)
downloadinfinitytier-0c8614b9c6ff049a1005b713e65365a3394d461c.tar.gz
infinitytier-0c8614b9c6ff049a1005b713e65365a3394d461c.zip
Add a second arg to idtool generate to make generating both secret and public easier, add new supernode identities after generating them, fix known good and bad IDs in selftest.
Diffstat (limited to 'selftest.cpp')
-rw-r--r--selftest.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/selftest.cpp b/selftest.cpp
index 521468cb..637b579e 100644
--- a/selftest.cpp
+++ b/selftest.cpp
@@ -207,9 +207,8 @@ static int testIdentity()
Identity id;
Buffer<512> buf;
-#if 0
std::cout << "[identity] Validate known-good identity... "; std::cout.flush();
- if (!id.fromString("0614d4a18e:0:ad2020bb575ace4397c490c9143718b43c9e78d3be72e1793a7380e45491d45ab7180443cca8f4f08ba5ea7e3466e76751039cb2554c19cf6540df7babed4037:6dcd4d5edf3b00659baea6ac75fabc9f82ada9a4e8d5618e663505ef16a301b3d0ff4cf6c663bbd0989dac42dcf2df29862fc83ee1d1a032d723d777bb78d08b")) {
+ if (!id.fromString(KNOWN_GOOD_IDENTITY)) {
std::cout << "FAIL (1)" << std::endl;
return -1;
}
@@ -218,10 +217,9 @@ static int testIdentity()
return -1;
}
std::cout << "PASS" << std::endl;
-#endif
std::cout << "[identity] Validate known-bad identity... "; std::cout.flush();
- if (!id.fromString("0615d4a18e:0:ad2020bb575ace4397c490c9143718b43c9e78d3be72e1793a7380e45491d45ab7180443cca8f4f08ba5ea7e3466e76751039cb2554c19cf6540df7babed4037:6dcd4d5edf3b00659baea6ac75fabc9f82ada9a4e8d5618e663505ef16a301b3d0ff4cf6c663bbd0989dac42dcf2df29862fc83ee1d1a032d723d777bb78d08b")) {
+ if (!id.fromString(KNOWN_BAD_IDENTITY)) {
std::cout << "FAIL (1)" << std::endl;
return -1;
}