trackler 2.2.1.42 → 2.2.1.43
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/trackler/version.rb +1 -1
- data/problem-specifications/exercises/change/metadata.yml +2 -0
- data/problem-specifications/exercises/crypto-square/canonical-data.json +10 -65
- data/tracks/c/bin/run-tests +3 -0
- data/tracks/c/exercises/acronym/test/test_acronym.c +8 -0
- data/tracks/c/exercises/all-your-base/test/test_all_your_base.c +19 -0
- data/tracks/c/exercises/allergies/test/test_allergies.c +13 -0
- data/tracks/c/exercises/anagram/src/anagram.h +2 -2
- data/tracks/c/exercises/anagram/src/example.c +5 -5
- data/tracks/c/exercises/anagram/test/test_anagram.c +39 -29
- data/tracks/c/exercises/atbash-cipher/test/test_atbash_cipher.c +12 -0
- data/tracks/c/exercises/beer-song/test/test_beer_song.c +5 -0
- data/tracks/c/exercises/binary-search/test/test_binary_search.c +10 -0
- data/tracks/c/exercises/binary/test/test_binary.c +14 -0
- data/tracks/c/exercises/bob/test/test_bob.c +16 -0
- data/tracks/c/exercises/clock/test/test_clock.c +34 -0
- data/tracks/c/exercises/difference-of-squares/test/test_difference_of_squares.c +9 -0
- data/tracks/c/exercises/gigasecond/test/test_gigasecond.c +4 -0
- data/tracks/c/exercises/grains/test/test_grains.c +9 -0
- data/tracks/c/exercises/hamming/test/test_hamming.c +12 -0
- data/tracks/c/exercises/isogram/src/example.c +6 -6
- data/tracks/c/exercises/isogram/src/example.h +1 -1
- data/tracks/c/exercises/isogram/test/test_isogram.c +17 -9
- data/tracks/c/exercises/largest-series-product/test/test_largest_series_product.c +15 -0
- data/tracks/c/exercises/leap/test/test_leap.c +4 -0
- data/tracks/c/exercises/nth-prime/test/test_nth_prime.c +4 -0
- data/tracks/c/exercises/nucleotide-count/test/test_nucleotide_count.c +4 -0
- data/tracks/c/exercises/palindrome-products/test/test_palindrome_products.c +1 -0
- data/tracks/c/exercises/pangram/test/test_pangram.c +11 -0
- data/tracks/c/exercises/pascals-triangle/test/test_pascals_triangle.c +5 -0
- data/tracks/c/exercises/perfect-numbers/test/test_perfect_numbers.c +12 -0
- data/tracks/c/exercises/phone-number/test/test_phone_number.c +13 -0
- data/tracks/c/exercises/raindrops/test/test_raindrops.c +17 -0
- data/tracks/c/exercises/react/test/test_react.c +14 -0
- data/tracks/c/exercises/rna-transcription/test/test_rna_transcription.c +7 -0
- data/tracks/c/exercises/robot-simulator/test/test_robot_simulator.c +11 -0
- data/tracks/c/exercises/roman-numerals/test/test_roman_numerals.c +17 -0
- data/tracks/c/exercises/scrabble-score/test/test_scrabble_score.c +10 -0
- data/tracks/c/exercises/sieve/test/test_sieve.c +4 -0
- data/tracks/c/exercises/space-age/test/test_space_age.c +7 -0
- data/tracks/c/exercises/sum-of-multiples/test/test_sum_of_multiples.c +11 -0
- data/tracks/c/exercises/triangle/test/test_triangle.c +15 -0
- data/tracks/c/exercises/word-count/test/test_word_count.c +10 -0
- data/tracks/dart/.travis.yml +2 -7
- data/tracks/dart/bin/check_formatting +9 -0
- data/tracks/dart/exercises/bob/pubspec.lock +26 -26
- data/tracks/dart/exercises/difference-of-squares/pubspec.lock +26 -26
- data/tracks/dart/exercises/gigasecond/pubspec.lock +26 -26
- data/tracks/dart/exercises/hamming/pubspec.lock +26 -26
- data/tracks/dart/exercises/hello-world/pubspec.lock +26 -26
- data/tracks/dart/exercises/leap/pubspec.lock +26 -26
- data/tracks/dart/exercises/rna-transcription/pubspec.lock +26 -26
- data/tracks/dart/exercises/rna-transcription/test/rna_transcription_test.dart +1 -1
- data/tracks/dart/pubspec.lock +42 -30
- data/tracks/dart/pubspec.yaml +3 -3
- data/tracks/dart/test/exercises_test.dart +52 -14
- data/tracks/dart/tool/create-exercise +1 -1
- data/tracks/erlang/.travis.yml +2 -2
- data/tracks/erlang/config.json +10 -0
- data/tracks/erlang/exercises/bank-account/src/example.erl +67 -41
- data/tracks/erlang/exercises/bank-account/test/bank_account_tests.erl +0 -6
- data/tracks/erlang/exercises/luhn/src/example.erl +32 -14
- data/tracks/erlang/exercises/luhn/test/luhn_tests.erl +36 -10
- data/tracks/erlang/exercises/two-fer/README.md +19 -0
- data/tracks/erlang/exercises/two-fer/include/exercism.hrl +11 -0
- data/tracks/erlang/exercises/two-fer/rebar.config +30 -0
- data/tracks/erlang/exercises/two-fer/src/example.erl +11 -0
- data/tracks/erlang/exercises/two-fer/src/two_fer.app.src +9 -0
- data/tracks/erlang/exercises/two-fer/src/two_fer.erl +11 -0
- data/tracks/erlang/exercises/two-fer/test/two_fer_tests.erl +15 -0
- data/tracks/java/config.json +26 -3
- data/tracks/java/exercises/list-ops/.meta/hints.md +4 -0
- data/tracks/javascript/config.json +14 -0
- data/tracks/javascript/docs/ABOUT.md +16 -9
- data/tracks/javascript/exercises/diffie-hellman/README.md +73 -0
- data/tracks/javascript/exercises/diffie-hellman/diffie-hellman.spec.js +73 -0
- data/tracks/javascript/exercises/diffie-hellman/example.js +48 -0
- data/tracks/julia/config.json +1 -1
- data/tracks/python/exercises/accumulate/accumulate.py +1 -1
- data/tracks/python/exercises/allergies/allergies.py +2 -2
- data/tracks/python/exercises/alphametics/alphametics.py +1 -1
- data/tracks/python/exercises/anagram/anagram.py +1 -1
- data/tracks/python/exercises/binary-search/binary_search.py +1 -1
- data/tracks/python/exercises/binary/binary.py +1 -1
- data/tracks/python/exercises/collatz-conjecture/collatz_conjecture.py +1 -1
- data/tracks/python/exercises/crypto-square/crypto_square.py +1 -1
- data/tracks/python/exercises/diamond/diamond.py +1 -1
- data/tracks/python/exercises/grep/grep.py +2 -0
- data/tracks/python/exercises/hello-world/hello_world.py +1 -1
- data/tracks/python/exercises/largest-series-product/largest_series_product.py +1 -1
- data/tracks/python/exercises/minesweeper/minesweeper.py +2 -1
- data/tracks/python/exercises/nucleotide-count/nucleotide_count.py +2 -2
- data/tracks/python/exercises/ocr-numbers/ocr_numbers.py +2 -2
- data/tracks/python/exercises/octal/octal.py +1 -1
- data/tracks/python/exercises/pangram/pangram.py +1 -1
- data/tracks/python/exercises/pascals-triangle/pascals_triangle.py +3 -3
- data/tracks/python/exercises/poker/poker.py +1 -1
- data/tracks/python/exercises/prime-factors/prime_factors.py +1 -1
- data/tracks/python/exercises/protein-translation/protein_translation.py +2 -2
- data/tracks/python/exercises/proverb/proverb.py +1 -1
- data/tracks/python/exercises/queen-attack/queen_attack.py +2 -2
- data/tracks/python/exercises/rail-fence-cipher/rail_fence_cipher.py +3 -3
- data/tracks/python/exercises/roman-numerals/roman_numerals.py +1 -1
- data/tracks/python/exercises/rotational-cipher/rotational_cipher.py +1 -1
- data/tracks/python/exercises/say/say.py +1 -1
- data/tracks/python/exercises/secret-handshake/secret_handshake.py +2 -2
- data/tracks/python/exercises/space-age/space_age.py +1 -1
- data/tracks/python/exercises/tournament/tournament.py +1 -1
- data/tracks/python/exercises/trinary/trinary.py +1 -1
- data/tracks/python/exercises/two-fer/two_fer.py +1 -1
- data/tracks/python/exercises/word-count/word_count.py +1 -1
- data/tracks/ruby/lib/generator/exercise_case.rb +1 -1
- data/tracks/ruby/test/generator/exercise_case_test.rb +10 -0
- data/tracks/scala/testgen/src/main/resources/version-check-ignore.txt +1 -2
- data/tracks/sml/exercises/accumulate/README.md +19 -14
- data/tracks/sml/exercises/accumulate/accumulate.sml +1 -1
- data/tracks/sml/exercises/accumulate/example.sml +2 -2
- data/tracks/sml/exercises/accumulate/test.sml +26 -56
- data/tracks/sml/exercises/accumulate/testlib.sml +159 -0
- metadata +15 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 34df3f47653a28428d9f5588ab2f351e03a061d8
|
|
4
|
+
data.tar.gz: c8a16096a4baaa4da33666a818d1f7ab231e3934
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4fcb85a26186da30f62ffbe241a7ee2f5dd79bb577948a23e1edbe871765eb17a295336d7504d796254ad71630dc0b92387e2c2ce526d38fb4f0bc44e098c1cb
|
|
7
|
+
data.tar.gz: c3ec3d29c0520e8de6a8cfd0330671d0eecebeeed90bfdfeaf041ea2cae79fa5280703df38eaee744cb62cceea96393cc8dbda4494c435c37ab185abad46a366
|
data/lib/trackler/version.rb
CHANGED
|
@@ -1,82 +1,27 @@
|
|
|
1
1
|
{
|
|
2
2
|
"exercise": "crypto-square",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"cases": [
|
|
5
5
|
{
|
|
6
6
|
"description": "the spaces and punctuation are removed from the English text and the message is downcased",
|
|
7
7
|
"cases": [
|
|
8
8
|
{
|
|
9
9
|
"description": "Lowercase",
|
|
10
|
-
"property": "
|
|
11
|
-
"plaintext": "
|
|
12
|
-
"expected": "
|
|
10
|
+
"property": "ciphertext",
|
|
11
|
+
"plaintext": "A",
|
|
12
|
+
"expected": "a"
|
|
13
13
|
},
|
|
14
14
|
{
|
|
15
15
|
"description": "Remove spaces",
|
|
16
|
-
"property": "
|
|
17
|
-
"plaintext": "
|
|
18
|
-
"expected": "
|
|
16
|
+
"property": "ciphertext",
|
|
17
|
+
"plaintext": " b ",
|
|
18
|
+
"expected": "b"
|
|
19
19
|
},
|
|
20
20
|
{
|
|
21
21
|
"description": "Remove punctuation",
|
|
22
|
-
"property": "
|
|
23
|
-
"plaintext": "@1
|
|
24
|
-
"expected": "
|
|
25
|
-
}
|
|
26
|
-
]
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
"description": "The plaintext should be organized in to a rectangle. The size of the rectangle (`r x c`) should be decided by the length of the message, such that `c >= r` and `c - r <= 1`, where `c` is the number of columns and `r` is the number of rows.",
|
|
30
|
-
"cases": [
|
|
31
|
-
{
|
|
32
|
-
"description": "empty plaintext results in an empty rectangle",
|
|
33
|
-
"property": "plaintextSegments",
|
|
34
|
-
"plaintext": "",
|
|
35
|
-
"expected": []
|
|
36
|
-
},
|
|
37
|
-
{
|
|
38
|
-
"description": "4 character plaintext results in an 2x2 rectangle",
|
|
39
|
-
"property": "plaintextSegments",
|
|
40
|
-
"plaintext": "Ab Cd",
|
|
41
|
-
"expected": [ "ab",
|
|
42
|
-
"cd" ]
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
"description": "9 character plaintext results in an 3x3 rectangle",
|
|
46
|
-
"property": "plaintextSegments",
|
|
47
|
-
"plaintext": "This is fun!",
|
|
48
|
-
"expected": [ "thi",
|
|
49
|
-
"sis",
|
|
50
|
-
"fun" ]
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
"description": "54 character plaintext results in an 8x7 rectangle",
|
|
54
|
-
"property": "plaintextSegments",
|
|
55
|
-
"plaintext": "If man was meant to stay on the ground, god would have given us roots.",
|
|
56
|
-
"expected": [ "ifmanwas",
|
|
57
|
-
"meanttos",
|
|
58
|
-
"tayonthe",
|
|
59
|
-
"groundgo",
|
|
60
|
-
"dwouldha",
|
|
61
|
-
"vegivenu",
|
|
62
|
-
"sroots" ]
|
|
63
|
-
}
|
|
64
|
-
]
|
|
65
|
-
},
|
|
66
|
-
{
|
|
67
|
-
"description": "The coded message is obtained by reading down the columns going left to right.",
|
|
68
|
-
"cases": [
|
|
69
|
-
{
|
|
70
|
-
"description": "empty plaintext results in an empty encode",
|
|
71
|
-
"property": "encoded",
|
|
72
|
-
"plaintext": "",
|
|
73
|
-
"expected": ""
|
|
74
|
-
},
|
|
75
|
-
{
|
|
76
|
-
"description": "Non-empty plaintext results in the combined plaintext segments",
|
|
77
|
-
"property": "encoded",
|
|
78
|
-
"plaintext": "If man was meant to stay on the ground, god would have given us roots.",
|
|
79
|
-
"expected": "imtgdvsfearwermayoogoanouuiontnnlvtwttddesaohghnsseoau"
|
|
22
|
+
"property": "ciphertext",
|
|
23
|
+
"plaintext": "@1,%!",
|
|
24
|
+
"expected": "1"
|
|
80
25
|
}
|
|
81
26
|
]
|
|
82
27
|
},
|
data/tracks/c/bin/run-tests
CHANGED
|
@@ -10,6 +10,9 @@ for D in exercises/*; do
|
|
|
10
10
|
STRIPPED_OF_EXTENSION="${TEST_FILE%.*}"
|
|
11
11
|
EXERCISE_NAME="${STRIPPED_OF_EXTENSION:5}"
|
|
12
12
|
|
|
13
|
+
#remove the ignore line
|
|
14
|
+
sed -i.bak 's/TEST_IGNORE();//' ${D}/test/test_*.c
|
|
15
|
+
|
|
13
16
|
# Copy the examples with the correct name for the exercise
|
|
14
17
|
if [ -e "${D}/src/example.c" ]
|
|
15
18
|
then
|
|
@@ -12,6 +12,7 @@ void test_abbreviation(char *phrase, char *expected)
|
|
|
12
12
|
|
|
13
13
|
void test_null_string(void)
|
|
14
14
|
{
|
|
15
|
+
TEST_IGNORE(); // delete this line to run test
|
|
15
16
|
char *phrase = NULL;
|
|
16
17
|
char *expected = NULL;
|
|
17
18
|
test_abbreviation(phrase, expected);
|
|
@@ -19,6 +20,7 @@ void test_null_string(void)
|
|
|
19
20
|
|
|
20
21
|
void test_empty_string(void)
|
|
21
22
|
{
|
|
23
|
+
TEST_IGNORE();
|
|
22
24
|
char *phrase = "";
|
|
23
25
|
char *expected = NULL;
|
|
24
26
|
test_abbreviation(phrase, expected);
|
|
@@ -26,6 +28,7 @@ void test_empty_string(void)
|
|
|
26
28
|
|
|
27
29
|
void test_basic_abbreviation(void)
|
|
28
30
|
{
|
|
31
|
+
TEST_IGNORE();
|
|
29
32
|
char *phrase = "Portable Network Graphics";
|
|
30
33
|
char *expected = "PNG";
|
|
31
34
|
test_abbreviation(phrase, expected);
|
|
@@ -33,6 +36,7 @@ void test_basic_abbreviation(void)
|
|
|
33
36
|
|
|
34
37
|
void test_lower_case_words(void)
|
|
35
38
|
{
|
|
39
|
+
TEST_IGNORE();
|
|
36
40
|
char *phrase = "Ruby on Rails";
|
|
37
41
|
char *expected = "ROR";
|
|
38
42
|
test_abbreviation(phrase, expected);
|
|
@@ -40,6 +44,7 @@ void test_lower_case_words(void)
|
|
|
40
44
|
|
|
41
45
|
void test_punctuation(void)
|
|
42
46
|
{
|
|
47
|
+
TEST_IGNORE();
|
|
43
48
|
char *phrase = "First In, First Out";
|
|
44
49
|
char *expected = "FIFO";
|
|
45
50
|
test_abbreviation(phrase, expected);
|
|
@@ -47,6 +52,7 @@ void test_punctuation(void)
|
|
|
47
52
|
|
|
48
53
|
void test_all_caps_words(void)
|
|
49
54
|
{
|
|
55
|
+
TEST_IGNORE();
|
|
50
56
|
char *phrase = "PHP: Hypertext Preprocessor";
|
|
51
57
|
char *expected = "PHP";
|
|
52
58
|
test_abbreviation(phrase, expected);
|
|
@@ -54,6 +60,7 @@ void test_all_caps_words(void)
|
|
|
54
60
|
|
|
55
61
|
void test_non_acronym_all_caps_words(void)
|
|
56
62
|
{
|
|
63
|
+
TEST_IGNORE();
|
|
57
64
|
char *phrase = "GNU Image Manipulation Program";
|
|
58
65
|
char *expected = "GIMP";
|
|
59
66
|
test_abbreviation(phrase, expected);
|
|
@@ -61,6 +68,7 @@ void test_non_acronym_all_caps_words(void)
|
|
|
61
68
|
|
|
62
69
|
void test_hyphenated(void)
|
|
63
70
|
{
|
|
71
|
+
TEST_IGNORE();
|
|
64
72
|
char *phrase = "Complementary metal-oxide semiconductor";
|
|
65
73
|
char *expected = "CMOS";
|
|
66
74
|
test_abbreviation(phrase, expected);
|
|
@@ -42,6 +42,7 @@ void test_single_bit_to_decimal(void)
|
|
|
42
42
|
|
|
43
43
|
void test_binary_to_single_decimal(void)
|
|
44
44
|
{
|
|
45
|
+
TEST_IGNORE(); // delete this line to run test
|
|
45
46
|
int8_t input[] = { 1, 0, 1 };
|
|
46
47
|
int8_t expected[] = { 5 };
|
|
47
48
|
test_rebase(2, input, LENGTH(input), 10, expected, LENGTH(expected));
|
|
@@ -49,6 +50,7 @@ void test_binary_to_single_decimal(void)
|
|
|
49
50
|
|
|
50
51
|
void test_single_decimal_to_binary(void)
|
|
51
52
|
{
|
|
53
|
+
TEST_IGNORE();
|
|
52
54
|
int8_t input[] = { 5 };
|
|
53
55
|
int8_t expected[] = { 1, 0, 1 };
|
|
54
56
|
test_rebase(10, input, LENGTH(input), 2, expected, LENGTH(expected));
|
|
@@ -56,6 +58,7 @@ void test_single_decimal_to_binary(void)
|
|
|
56
58
|
|
|
57
59
|
void test_binary_to_multiple_decimal(void)
|
|
58
60
|
{
|
|
61
|
+
TEST_IGNORE();
|
|
59
62
|
int8_t input[] = { 1, 0, 1, 0, 1, 0 };
|
|
60
63
|
int8_t expected[] = { 4, 2 };
|
|
61
64
|
test_rebase(2, input, LENGTH(input), 10, expected, LENGTH(expected));
|
|
@@ -63,6 +66,7 @@ void test_binary_to_multiple_decimal(void)
|
|
|
63
66
|
|
|
64
67
|
void test_decimal_to_binary(void)
|
|
65
68
|
{
|
|
69
|
+
TEST_IGNORE();
|
|
66
70
|
int8_t input[] = { 4, 2 };
|
|
67
71
|
int8_t expected[] = { 1, 0, 1, 0, 1, 0 };
|
|
68
72
|
test_rebase(10, input, LENGTH(input), 2, expected, LENGTH(expected));
|
|
@@ -70,6 +74,7 @@ void test_decimal_to_binary(void)
|
|
|
70
74
|
|
|
71
75
|
void test_trinary_to_hex(void)
|
|
72
76
|
{
|
|
77
|
+
TEST_IGNORE();
|
|
73
78
|
int8_t input[] = { 1, 1, 2, 0 };
|
|
74
79
|
int8_t expected[] = { 2, 10 };
|
|
75
80
|
test_rebase(3, input, LENGTH(input), 16, expected, LENGTH(expected));
|
|
@@ -77,6 +82,7 @@ void test_trinary_to_hex(void)
|
|
|
77
82
|
|
|
78
83
|
void test_hex_to_trinary(void)
|
|
79
84
|
{
|
|
85
|
+
TEST_IGNORE();
|
|
80
86
|
int8_t input[] = { 2, 10 };
|
|
81
87
|
int8_t expected[] = { 1, 1, 2, 0 };
|
|
82
88
|
test_rebase(16, input, LENGTH(input), 3, expected, LENGTH(expected));
|
|
@@ -84,6 +90,7 @@ void test_hex_to_trinary(void)
|
|
|
84
90
|
|
|
85
91
|
void test_15_bit_integer(void)
|
|
86
92
|
{
|
|
93
|
+
TEST_IGNORE();
|
|
87
94
|
int8_t input[] = { 3, 46, 60 };
|
|
88
95
|
int8_t expected[] = { 6, 10, 45 };
|
|
89
96
|
test_rebase(97, input, LENGTH(input), 73, expected, LENGTH(expected));
|
|
@@ -91,6 +98,7 @@ void test_15_bit_integer(void)
|
|
|
91
98
|
|
|
92
99
|
void test_single_zero(void)
|
|
93
100
|
{
|
|
101
|
+
TEST_IGNORE();
|
|
94
102
|
int8_t input[] = { 0 };
|
|
95
103
|
int8_t expected[] = { 0 };
|
|
96
104
|
test_rebase(2, input, LENGTH(input), 10, expected, 0);
|
|
@@ -98,6 +106,7 @@ void test_single_zero(void)
|
|
|
98
106
|
|
|
99
107
|
void test_multiple_zeros(void)
|
|
100
108
|
{
|
|
109
|
+
TEST_IGNORE();
|
|
101
110
|
int8_t input[] = { 0, 0, 0 };
|
|
102
111
|
int8_t expected[] = { 0 };
|
|
103
112
|
test_rebase(10, input, LENGTH(input), 2, expected, 0);
|
|
@@ -105,6 +114,7 @@ void test_multiple_zeros(void)
|
|
|
105
114
|
|
|
106
115
|
void test_leading_zeros(void)
|
|
107
116
|
{
|
|
117
|
+
TEST_IGNORE();
|
|
108
118
|
int8_t input[] = { 0, 6, 0 };
|
|
109
119
|
int8_t expected[] = { 0 };
|
|
110
120
|
test_rebase(7, input, LENGTH(input), 10, expected, 0);
|
|
@@ -112,6 +122,7 @@ void test_leading_zeros(void)
|
|
|
112
122
|
|
|
113
123
|
void test_first_base_is_one(void)
|
|
114
124
|
{
|
|
125
|
+
TEST_IGNORE();
|
|
115
126
|
int8_t input[] = { 0 };
|
|
116
127
|
int8_t expected[] = { 0 };
|
|
117
128
|
test_rebase(1, input, LENGTH(input), 10, expected, 0);
|
|
@@ -119,6 +130,7 @@ void test_first_base_is_one(void)
|
|
|
119
130
|
|
|
120
131
|
void test_first_base_is_zero(void)
|
|
121
132
|
{
|
|
133
|
+
TEST_IGNORE();
|
|
122
134
|
int8_t input[] = { 0 };
|
|
123
135
|
int8_t expected[] = { 0 };
|
|
124
136
|
test_rebase(0, input, LENGTH(input), 10, expected, 0);
|
|
@@ -126,6 +138,7 @@ void test_first_base_is_zero(void)
|
|
|
126
138
|
|
|
127
139
|
void test_first_base_is_negative(void)
|
|
128
140
|
{
|
|
141
|
+
TEST_IGNORE();
|
|
129
142
|
int8_t input[] = { 1 };
|
|
130
143
|
int8_t expected[] = { 0 };
|
|
131
144
|
test_rebase(-2, input, LENGTH(input), 10, expected, 0);
|
|
@@ -133,6 +146,7 @@ void test_first_base_is_negative(void)
|
|
|
133
146
|
|
|
134
147
|
void test_negative_digit(void)
|
|
135
148
|
{
|
|
149
|
+
TEST_IGNORE();
|
|
136
150
|
int8_t input[] = { 1, -1, 1, 0, 1, 0 };
|
|
137
151
|
int8_t expected[] = { 0 };
|
|
138
152
|
test_rebase(2, input, LENGTH(input), 10, expected, 0);
|
|
@@ -140,6 +154,7 @@ void test_negative_digit(void)
|
|
|
140
154
|
|
|
141
155
|
void test_invalid_positive_digit(void)
|
|
142
156
|
{
|
|
157
|
+
TEST_IGNORE();
|
|
143
158
|
int8_t input[] = { 1, 2, 1, 0, 1, 0 };
|
|
144
159
|
int8_t expected[] = { 0 };
|
|
145
160
|
test_rebase(2, input, LENGTH(input), 10, expected, 0);
|
|
@@ -147,6 +162,7 @@ void test_invalid_positive_digit(void)
|
|
|
147
162
|
|
|
148
163
|
void test_second_base_is_one(void)
|
|
149
164
|
{
|
|
165
|
+
TEST_IGNORE();
|
|
150
166
|
int8_t input[] = { 1, 0, 1, 0, 1, 0 };
|
|
151
167
|
int8_t expected[] = { 0 };
|
|
152
168
|
test_rebase(2, input, LENGTH(input), 1, expected, 0);
|
|
@@ -154,6 +170,7 @@ void test_second_base_is_one(void)
|
|
|
154
170
|
|
|
155
171
|
void test_second_base_is_zero(void)
|
|
156
172
|
{
|
|
173
|
+
TEST_IGNORE();
|
|
157
174
|
int8_t input[] = { 7 };
|
|
158
175
|
int8_t expected[] = { 0 };
|
|
159
176
|
test_rebase(10, input, LENGTH(input), 0, expected, 0);
|
|
@@ -161,6 +178,7 @@ void test_second_base_is_zero(void)
|
|
|
161
178
|
|
|
162
179
|
void test_second_base_is_negative(void)
|
|
163
180
|
{
|
|
181
|
+
TEST_IGNORE();
|
|
164
182
|
int8_t input[] = { 1 };
|
|
165
183
|
int8_t expected[] = { 0 };
|
|
166
184
|
test_rebase(2, input, LENGTH(input), -7, expected, 0);
|
|
@@ -168,6 +186,7 @@ void test_second_base_is_negative(void)
|
|
|
168
186
|
|
|
169
187
|
void test_both_bases_are_negative(void)
|
|
170
188
|
{
|
|
189
|
+
TEST_IGNORE();
|
|
171
190
|
int8_t input[] = { 1 };
|
|
172
191
|
int8_t expected[] = { 0 };
|
|
173
192
|
test_rebase(-2, input, LENGTH(input), -7, expected, 0);
|
|
@@ -9,6 +9,7 @@ void test_list_count_is(int count, allergen_list_t * list)
|
|
|
9
9
|
|
|
10
10
|
void test_list_contains(allergen_t allergen, allergen_list_t * list)
|
|
11
11
|
{
|
|
12
|
+
TEST_IGNORE(); // delete this line to run test
|
|
12
13
|
bool allergen_found = false;
|
|
13
14
|
|
|
14
15
|
for (int i = 0; i < list->count; i++) {
|
|
@@ -23,6 +24,7 @@ void test_list_contains(allergen_t allergen, allergen_list_t * list)
|
|
|
23
24
|
|
|
24
25
|
void test_no_allergies_means_not_allergic(void)
|
|
25
26
|
{
|
|
27
|
+
TEST_IGNORE();
|
|
26
28
|
int score = 0;
|
|
27
29
|
|
|
28
30
|
TEST_ASSERT_FALSE(is_allergic_to(allergen_peanuts, score));
|
|
@@ -32,6 +34,7 @@ void test_no_allergies_means_not_allergic(void)
|
|
|
32
34
|
|
|
33
35
|
void test_is_allergic_to_eggs(void)
|
|
34
36
|
{
|
|
37
|
+
TEST_IGNORE();
|
|
35
38
|
int score = 1;
|
|
36
39
|
|
|
37
40
|
TEST_ASSERT_TRUE(is_allergic_to(allergen_eggs, score));
|
|
@@ -39,6 +42,7 @@ void test_is_allergic_to_eggs(void)
|
|
|
39
42
|
|
|
40
43
|
void test_is_allergic_to_eggs_in_addition_to_other_stuff(void)
|
|
41
44
|
{
|
|
45
|
+
TEST_IGNORE();
|
|
42
46
|
int score = 5;
|
|
43
47
|
|
|
44
48
|
TEST_ASSERT_TRUE(is_allergic_to(allergen_eggs, score));
|
|
@@ -48,6 +52,7 @@ void test_is_allergic_to_eggs_in_addition_to_other_stuff(void)
|
|
|
48
52
|
|
|
49
53
|
void test_no_allergies_at_all(void)
|
|
50
54
|
{
|
|
55
|
+
TEST_IGNORE();
|
|
51
56
|
int score = 0;
|
|
52
57
|
allergen_list_t list;
|
|
53
58
|
|
|
@@ -60,6 +65,7 @@ void test_no_allergies_at_all(void)
|
|
|
60
65
|
|
|
61
66
|
void test_allergic_to_just_eggs(void)
|
|
62
67
|
{
|
|
68
|
+
TEST_IGNORE();
|
|
63
69
|
int score = 1;
|
|
64
70
|
allergen_list_t list;
|
|
65
71
|
|
|
@@ -73,6 +79,7 @@ void test_allergic_to_just_eggs(void)
|
|
|
73
79
|
|
|
74
80
|
void test_allergic_to_just_peanuts(void)
|
|
75
81
|
{
|
|
82
|
+
TEST_IGNORE();
|
|
76
83
|
int score = 2;
|
|
77
84
|
allergen_list_t list;
|
|
78
85
|
|
|
@@ -86,6 +93,7 @@ void test_allergic_to_just_peanuts(void)
|
|
|
86
93
|
|
|
87
94
|
void test_allergic_to_just_strawberries(void)
|
|
88
95
|
{
|
|
96
|
+
TEST_IGNORE();
|
|
89
97
|
int score = 8;
|
|
90
98
|
allergen_list_t list;
|
|
91
99
|
|
|
@@ -99,6 +107,7 @@ void test_allergic_to_just_strawberries(void)
|
|
|
99
107
|
|
|
100
108
|
void test_allergic_to_eggs_and_peanuts(void)
|
|
101
109
|
{
|
|
110
|
+
TEST_IGNORE();
|
|
102
111
|
int score = 3;
|
|
103
112
|
allergen_list_t list;
|
|
104
113
|
|
|
@@ -113,6 +122,7 @@ void test_allergic_to_eggs_and_peanuts(void)
|
|
|
113
122
|
|
|
114
123
|
void test_allergic_to_more_than_eggs_but_not_peanuts(void)
|
|
115
124
|
{
|
|
125
|
+
TEST_IGNORE();
|
|
116
126
|
int score = 5;
|
|
117
127
|
allergen_list_t list;
|
|
118
128
|
|
|
@@ -127,6 +137,7 @@ void test_allergic_to_more_than_eggs_but_not_peanuts(void)
|
|
|
127
137
|
|
|
128
138
|
void test_allergic_to_lots_of_stuff(void)
|
|
129
139
|
{
|
|
140
|
+
TEST_IGNORE();
|
|
130
141
|
int score = 248;
|
|
131
142
|
allergen_list_t list;
|
|
132
143
|
|
|
@@ -144,6 +155,7 @@ void test_allergic_to_lots_of_stuff(void)
|
|
|
144
155
|
|
|
145
156
|
void test_allergic_to_everything(void)
|
|
146
157
|
{
|
|
158
|
+
TEST_IGNORE();
|
|
147
159
|
int score = 255;
|
|
148
160
|
allergen_list_t list;
|
|
149
161
|
|
|
@@ -164,6 +176,7 @@ void test_allergic_to_everything(void)
|
|
|
164
176
|
|
|
165
177
|
void test_ignore_non_allergen_score_parts(void)
|
|
166
178
|
{
|
|
179
|
+
TEST_IGNORE();
|
|
167
180
|
int score = 509;
|
|
168
181
|
allergen_list_t list;
|
|
169
182
|
|