Skip to content

Commit

Permalink
Add tests
Browse files Browse the repository at this point in the history
Signed-off-by: Ivan Rogach <[email protected]>
  • Loading branch information
jannejy committed Nov 19, 2024
1 parent d8d064a commit 0b01822
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/tests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,13 @@ TEST_F(EvseSecurityTests, retrieve_root_ca) {
ASSERT_EQ(path, retrieved_path);
}

TEST_F(EvseSecurityTests, retrieve_root_location) {
std::string file_path = "certs/ca/v2g/V2G_CA_BUNDLE.pem";
std::string retrieved_file_location = this->evse_security->get_verify_location(CaCertificateType::V2G);

ASSERT_EQ(file_path, retrieved_file_location);
}

TEST_F(EvseSecurityTests, install_root_ca_01) {
const auto v2g_root_ca = read_file_to_string(fs::path("certs/ca/v2g/V2G_ROOT_CA_NEW.pem"));
const auto result = this->evse_security->install_ca_certificate(v2g_root_ca, CaCertificateType::V2G);
Expand Down

0 comments on commit 0b01822

Please sign in to comment.