1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-04 15:30:01 +00:00

Improve GalileoISMTest

This commit is contained in:
Carles Fernandez 2024-09-21 13:26:27 +02:00
parent 311b0ea6f2
commit 84b86107a7
No known key found for this signature in database
GPG Key ID: 4C583C52B0C3877D

View File

@ -26,11 +26,10 @@ TEST(GalileoISMTest, CRC)
bool result = gal_ism.check_ism_crc(input);
EXPECT_TRUE(result);
// Check if it can be used twice
std::bitset<128> input2 = input;
bool result2 = gal_ism.check_ism_crc(input2);
bool result2 = gal_ism.check_ism_crc(input);
EXPECT_TRUE(result2);
// Check if it fails
input2.set(127);
bool result3 = gal_ism.check_ism_crc(input2);
input.set(127);
bool result3 = gal_ism.check_ism_crc(input);
EXPECT_TRUE(!result3);
}