aboutsummaryrefslogtreecommitdiffstats
path: root/tests/edge
diff options
context:
space:
mode:
authorMax <msuraev@sysmocom.de>2019-03-13 16:35:09 +0100
committerMax <msuraev@sysmocom.de>2019-03-24 18:54:52 +0100
commita4de02db5db1e90eee071d62a4a502d8cde4b8a7 (patch)
tree25933b45ab1ce68cf3d7c5035b4f4b4fae98eaf2 /tests/edge
parent02fbfc15c7678cb02a19b4c2f01f9efc80756d14 (diff)
MCS: move Mode enum outside of class definition
Move Mode (EDGE/GPRS) definition and related functions outside of GprsCodingScheme class. This allows us to use standard libosmocore value_string functions. Change-Id: I3baaac7f1ca3f5b88917a23c1679d63847455f47
Diffstat (limited to 'tests/edge')
-rw-r--r--tests/edge/EdgeTest.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/edge/EdgeTest.cpp b/tests/edge/EdgeTest.cpp
index 41a11159..b9028061 100644
--- a/tests/edge/EdgeTest.cpp
+++ b/tests/edge/EdgeTest.cpp
@@ -48,7 +48,7 @@ void *tall_pcu_ctx;
int16_t spoof_mnc = 0, spoof_mcc = 0;
bool spoof_mnc_3_digits = false;
-static void check_coding_scheme(GprsCodingScheme& cs, GprsCodingScheme::Mode mode)
+static void check_coding_scheme(GprsCodingScheme& cs, enum mcs_kind mode)
{
volatile unsigned expected_size;
bool need_padding;
@@ -148,9 +148,9 @@ static void test_coding_scheme()
OSMO_ASSERT(!cs);
OSMO_ASSERT(CodingScheme(cs) == UNKNOWN);
OSMO_ASSERT(cs == GprsCodingScheme(UNKNOWN));
- OSMO_ASSERT(!cs.isCompatible(GprsCodingScheme::GPRS));
- OSMO_ASSERT(!cs.isCompatible(GprsCodingScheme::EGPRS_GMSK));
- OSMO_ASSERT(!cs.isCompatible(GprsCodingScheme::EGPRS));
+ OSMO_ASSERT(!cs.isCompatible(GPRS));
+ OSMO_ASSERT(!cs.isCompatible(EGPRS_GMSK));
+ OSMO_ASSERT(!cs.isCompatible(EGPRS));
last_size_UL = 0;
last_size_DL = 0;
@@ -170,7 +170,7 @@ static void test_coding_scheme()
/* Check header types */
OSMO_ASSERT(current_cs.headerTypeData() == HEADER_GPRS_DATA);
- check_coding_scheme(current_cs, GprsCodingScheme::GPRS);
+ check_coding_scheme(current_cs, GPRS);
}
OSMO_ASSERT(i == 4);
@@ -190,8 +190,8 @@ static void test_coding_scheme()
last_size_DL = current_cs.maxBytesDL();
if (egprs_schemes[i].is_gmsk)
- check_coding_scheme(current_cs, GprsCodingScheme::EGPRS_GMSK);
- check_coding_scheme(current_cs, GprsCodingScheme::EGPRS);
+ check_coding_scheme(current_cs, EGPRS_GMSK);
+ check_coding_scheme(current_cs, EGPRS);
}
OSMO_ASSERT(i == 9);