#include "gtest/gtest.h"
#include "crypto/crypto.h"
Go to the source code of this file.
◆ message()
| std::string message |
( |
"Message requiring signing" |
| ) |
|
◆ TEST() [1/3]
Definition at line 16 of file delegated_pow.cpp.
std::vector< std::string > keypair
#define ASSERT_EQ(val1, val2)
◆ TEST() [2/3]
| TEST |
( |
DelegatedPOW |
, |
|
|
SignMessage |
|
|
) |
| |
Definition at line 25 of file delegated_pow.cpp.
#define ASSERT_EQ(val1, val2)
std::string invalidSignature
std::string blankInvalidSignature
std::string validSignature
◆ TEST() [3/3]
| TEST |
( |
DelegatedPOW |
, |
|
|
VerifySignature |
|
|
) |
| |
Definition at line 32 of file delegated_pow.cpp.
std::string unusedMessage("Unused message")
#define EXPECT_TRUE(condition)
bool verify_signature(const std::string &message, const std::string &publicKey, const std::string &signature)
std::string message("Message requiring signing")
std::string invalidSignature
#define EXPECT_FALSE(condition)
std::string validSignature
◆ unusedMessage()
| std::string unusedMessage |
( |
"Unused message" |
| ) |
|
◆ blankInvalidSignature
◆ invalidSignature
◆ keypair
◆ privateKey
| std::string privateKey = boost::algorithm::unhex(keypair[0]) |
◆ publicKey
| std::string publicKey = boost::algorithm::unhex(keypair[1]) |
◆ validSignature