~aleteoryx/muditaos

ref: 48d31b876cf6fed438676e4fa73b6e16b1f6b3a7 muditaos/module-services/service-cellular/tests/unittest_simcard.cpp -rw-r--r-- 548 bytes
48d31b87 — tomaszkrosnowski [EGD-6311] Audio settings windows 4 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// Copyright (c) 2017-2020, Mudita Sp. z.o.o. All rights reserved.
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md

#define CATCH_CONFIG_MAIN

#include <catch2/catch.hpp>
#include <service-cellular/SimCard.hpp>

using namespace cellular;

TEST_CASE("SimCard functionality test")
{
    SECTION("pinToString from vector")
    {
        std::vector<unsigned int> v{1, 2, 3, 4};
        std::vector<unsigned int> empty;
        REQUIRE(SimCard::pinToString(v) == "1234");
        REQUIRE(SimCard::pinToString(empty) == "");
    }
}