Skip to content

Commit 334c02f

Browse files
committed
Cellular: not-supported error if MODEM_ON_BOARD not defined
If a test is empty, it leads to undef. Therefore if a test requires additional details, it should print an error [NOT SUPPORTED].
1 parent 9b082ff commit 334c02f

File tree

1 file changed

+3
-12
lines changed
  • features/netsocket/cellular/generic_modem_driver/TESTS/unit_tests/default

1 file changed

+3
-12
lines changed

features/netsocket/cellular/generic_modem_driver/TESTS/unit_tests/default/main.cpp

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
* limitations under the License.
1515
*/
1616

17-
#if MODEM_ON_BOARD
17+
#if !MODEM_ON_BOARD
18+
#error [NOT_SUPPORTED] MODEM_ON_BOARD should be set for this test to be functional
19+
#endif
1820

1921
#include "mbed.h"
2022
#include "gmd_ut_config_header.h"
@@ -436,14 +438,3 @@ static void unlock()
436438
{
437439
mtx.unlock();
438440
}
439-
440-
#else
441-
442-
int main ()
443-
{
444-
return 0;
445-
}
446-
447-
#endif //MODEM_ON_BOARD
448-
// End Of File
449-

0 commit comments

Comments
 (0)