@@ -366,112 +366,52 @@ FOSSIL_TEST_CASE(cpp_assume_run_of_hex64_shortcut) {
366366 ASSUME_ITS_LESS_OR_EQUAL_H64 ((int )y, (int )x);
367367} // end case
368368
369- FOSSIL_TEST_CASE (cpp_assume_run_of_octal) {
370- int x = 052 ; // Octal for 42
371- int y = 024 ; // Octal for 20
372-
373- // Test cases
374- FOSSIL_TEST_ASSUME (x == 042 , " Should have passed the test case" );
375- FOSSIL_TEST_ASSUME (y == 020 , " Should have passed the test case" );
376- FOSSIL_TEST_ASSUME (x != y, " Should have passed the test case" );
377- FOSSIL_TEST_ASSUME (y < x, " Should have passed the test case" );
378- FOSSIL_TEST_ASSUME (y <= x, " Should have passed the test case" );
379- } // end case
380-
381- FOSSIL_TEST_CASE (cpp_assume_run_of_octal8) {
382- int x = 052 ; // Octal for 42
383- int y = 024 ; // Octal for 20
384-
385- // Test cases
386- FOSSIL_TEST_ASSUME (x == 042 , " Should have passed the test case" );
387- FOSSIL_TEST_ASSUME (y == 020 , " Should have passed the test case" );
388- FOSSIL_TEST_ASSUME (x != y, " Should have passed the test case" );
389- FOSSIL_TEST_ASSUME (y < x, " Should have passed the test case" );
390- FOSSIL_TEST_ASSUME (y <= x, " Should have passed the test case" );
391- } // end case
392-
393- FOSSIL_TEST_CASE (cpp_assume_run_of_octal16) {
394- int x = 052 ; // Octal for 42
395- int y = 024 ; // Octal for 20
396-
397- // Test cases
398- FOSSIL_TEST_ASSUME (x == 042 , " Should have passed the test case" );
399- FOSSIL_TEST_ASSUME (y == 020 , " Should have passed the test case" );
400- FOSSIL_TEST_ASSUME (x != y, " Should have passed the test case" );
401- FOSSIL_TEST_ASSUME (y < x, " Should have passed the test case" );
402- FOSSIL_TEST_ASSUME (y <= x, " Should have passed the test case" );
403- } // end case
404-
405- FOSSIL_TEST_CASE (cpp_assume_run_of_octal32) {
406- int x = 052 ; // Octal for 42
407- int y = 024 ; // Octal for 20
408-
409- // Test cases
410- FOSSIL_TEST_ASSUME (x == 042 , " Should have passed the test case" );
411- FOSSIL_TEST_ASSUME (y == 020 , " Should have passed the test case" );
412- FOSSIL_TEST_ASSUME (x != y, " Should have passed the test case" );
413- FOSSIL_TEST_ASSUME (y < x, " Should have passed the test case" );
414- FOSSIL_TEST_ASSUME (y <= x, " Should have passed the test case" );
415- } // end case
416-
417- FOSSIL_TEST_CASE (cpp_assume_run_of_octal64) {
418- int x = 052 ; // Octal for 42
419- int y = 024 ; // Octal for 20
420-
421- // Test cases
422- FOSSIL_TEST_ASSUME (x == 042 , " Should have passed the test case" );
423- FOSSIL_TEST_ASSUME (y == 020 , " Should have passed the test case" );
424- FOSSIL_TEST_ASSUME (x != y, " Should have passed the test case" );
425- FOSSIL_TEST_ASSUME (y < x, " Should have passed the test case" );
426- FOSSIL_TEST_ASSUME (y <= x, " Should have passed the test case" );
427- } // end case
428-
429369FOSSIL_TEST_CASE (cpp_assume_run_of_octal8_shortcut) {
430- int x = 052 ; // Octal for 42
431- int y = 024 ; // Octal for 20
370+ int8_t x = 042 ; // Octal for 42
371+ int8_t y = 020 ; // Octal for 20
432372
433373 // Test cases
434- ASSUME_ITS_EQUAL_O8 ((int )x, 042 );
435- ASSUME_ITS_EQUAL_O8 ((int )y, 020 );
436- ASSUME_NOT_EQUAL_O8 ((int )x, (int )y);
437- ASSUME_ITS_LESS_THAN_O8 ((int )y, (int )x);
438- ASSUME_ITS_LESS_OR_EQUAL_O8 ((int )y, (int )x);
374+ ASSUME_ITS_EQUAL_O8 ((int8_t )x, 042 );
375+ ASSUME_ITS_EQUAL_O8 ((int8_t )y, 020 );
376+ ASSUME_NOT_EQUAL_O8 ((int8_t )x, (int8_t )y);
377+ ASSUME_ITS_LESS_THAN_O8 ((int8_t )y, (int8_t )x);
378+ ASSUME_ITS_LESS_OR_EQUAL_O8 ((int8_t )y, (int8_t )x);
439379} // end case
440380
441381FOSSIL_TEST_CASE (cpp_assume_run_of_octal16_shortcut) {
442- int x = 052 ; // Octal for 42
443- int y = 024 ; // Octal for 20
382+ int16_t x = 042 ; // Octal for 42
383+ int16_t y = 020 ; // Octal for 20
444384
445385 // Test cases
446- ASSUME_ITS_EQUAL_O16 ((int )x, 042 );
447- ASSUME_ITS_EQUAL_O16 ((int )y, 020 );
448- ASSUME_NOT_EQUAL_O16 ((int )x, (int )y);
449- ASSUME_ITS_LESS_THAN_O16 ((int )y, (int )x);
450- ASSUME_ITS_LESS_OR_EQUAL_O16 ((int )y, (int )x);
386+ ASSUME_ITS_EQUAL_O16 ((int16_t )x, 042 );
387+ ASSUME_ITS_EQUAL_O16 ((int16_t )y, 020 );
388+ ASSUME_NOT_EQUAL_O16 ((int16_t )x, (int16_t )y);
389+ ASSUME_ITS_LESS_THAN_O16 ((int16_t )y, (int16_t )x);
390+ ASSUME_ITS_LESS_OR_EQUAL_O16 ((int16_t )y, (int16_t )x);
451391} // end case
452392
453393FOSSIL_TEST_CASE (cpp_assume_run_of_octal32_shortcut) {
454- int x = 052 ; // Octal for 42
455- int y = 024 ; // Octal for 20
394+ int32_t x = 042 ; // Octal for 42
395+ int32_t y = 020 ; // Octal for 20
456396
457397 // Test cases
458- ASSUME_ITS_EQUAL_O32 ((int )x, 042 );
459- ASSUME_ITS_EQUAL_O32 ((int )y, 020 );
460- ASSUME_NOT_EQUAL_O32 ((int )x, (int )y);
461- ASSUME_ITS_LESS_THAN_O32 ((int )y, (int )x);
462- ASSUME_ITS_LESS_OR_EQUAL_O32 ((int )y, (int )x);
398+ ASSUME_ITS_EQUAL_O32 ((int32_t )x, 042 );
399+ ASSUME_ITS_EQUAL_O32 ((int32_t )y, 020 );
400+ ASSUME_NOT_EQUAL_O32 ((int32_t )x, (int32_t )y);
401+ ASSUME_ITS_LESS_THAN_O32 ((int32_t )y, (int32_t )x);
402+ ASSUME_ITS_LESS_OR_EQUAL_O32 ((int32_t )y, (int32_t )x);
463403} // end case
464404
465405FOSSIL_TEST_CASE (cpp_assume_run_of_octal64_shortcut) {
466- int x = 052 ; // Octal for 42
467- int y = 024 ; // Octal for 20
406+ int64_t x = 042 ; // Octal for 42
407+ int64_t y = 020 ; // Octal for 20
468408
469409 // Test cases
470- ASSUME_ITS_EQUAL_O64 ((int )x, 042 );
471- ASSUME_ITS_EQUAL_O64 ((int )y, 020 );
472- ASSUME_NOT_EQUAL_O64 ((int )x, (int )y);
473- ASSUME_ITS_LESS_THAN_O64 ((int )y, (int )x);
474- ASSUME_ITS_LESS_OR_EQUAL_O64 ((int )y, (int )x);
410+ ASSUME_ITS_EQUAL_O64 ((int64_t )x, 042 );
411+ ASSUME_ITS_EQUAL_O64 ((int64_t )y, 020 );
412+ ASSUME_NOT_EQUAL_O64 ((int64_t )x, (int64_t )y);
413+ ASSUME_ITS_LESS_THAN_O64 ((int64_t )y, (int64_t )x);
414+ ASSUME_ITS_LESS_OR_EQUAL_O64 ((int64_t )y, (int64_t )x);
475415} // end case
476416
477417FOSSIL_TEST_CASE (cpp_assume_run_of_float32) {
@@ -798,11 +738,6 @@ FOSSIL_TEST_GROUP(cpp_tdd_test_cases) {
798738 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_hex16_shortcut);
799739 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_hex32_shortcut);
800740 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_hex64_shortcut);
801- FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_octal);
802- FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_octal8);
803- FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_octal16);
804- FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_octal32);
805- FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_octal64);
806741 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_octal8_shortcut);
807742 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_octal16_shortcut);
808743 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_octal32_shortcut);
@@ -819,20 +754,20 @@ FOSSIL_TEST_GROUP(cpp_tdd_test_cases) {
819754 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_pointer_equality);
820755 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_size_equality);
821756 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_size_comparison);
822- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range);
823- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_u8);
824- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_u16);
825- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_u32);
826- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_u64);
827- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_i8);
828- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_i16);
829- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_i32);
830- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_i64);
831- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_f32);
832- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_f64);
833- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_bchar);
834- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_cchar);
835- // FOSSIL_TEST_ADD(cpp_tdd_suite, cpp_assume_run_of_within_range_wchar);
757+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range);
758+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_u8);
759+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_u16);
760+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_u32);
761+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_u64);
762+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_i8);
763+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_i16);
764+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_i32);
765+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_i64);
766+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_f32);
767+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_f64);
768+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_bchar);
769+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_cchar);
770+ FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_within_range_wchar);
836771 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_wstr);
837772 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_bstr);
838773 FOSSIL_TEST_ADD (cpp_tdd_suite, cpp_assume_run_of_cstr);
0 commit comments