trackler 2.0.6.33 → 2.0.6.34
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/trackler/version.rb +1 -1
- data/tracks/delphi/exercises/beer-song/inputdata.txt +7 -0
- data/tracks/delphi/exercises/beer-song/uBeerSongExample.pas +12 -12
- data/tracks/delphi/exercises/beer-song/uBeerSongTests.pas +74 -59
- data/tracks/elixir/exercises/grains/example.exs +3 -2
- data/tracks/elixir/exercises/grains/grains_test.exs +24 -8
- data/tracks/go/exercises/binary-search/binary_search_test.go +8 -0
- data/tracks/go/exercises/binary-search/example.go +2 -0
- data/tracks/go/exercises/binary/binary_test.go +5 -2
- data/tracks/go/exercises/variable-length-quantity/example.go +2 -0
- data/tracks/go/exercises/variable-length-quantity/variable_length_quantity_test.go +8 -0
- data/tracks/go/exercises/word-count/word_count_test.go +4 -1
- data/tracks/julia/config.json +26 -0
- data/tracks/julia/exercises/gigasecond/example.jl +1 -0
- data/tracks/julia/exercises/gigasecond/gigasecond.jl +3 -0
- data/tracks/julia/exercises/gigasecond/runtests.jl +15 -0
- data/tracks/julia/exercises/roman-numerals/example.jl +21 -0
- data/tracks/julia/exercises/roman-numerals/roman-numerals.jl +3 -0
- data/tracks/julia/exercises/roman-numerals/runtests.jl +37 -0
- data/tracks/julia/exercises/transpose/example.jl +20 -0
- data/tracks/julia/exercises/transpose/runtests.jl +212 -0
- data/tracks/julia/exercises/transpose/transpose.jl +3 -0
- data/tracks/kotlin/.travis.yml +5 -2
- data/tracks/kotlin/bin/{build.sh → unit-tests.sh} +8 -6
- data/tracks/kotlin/exercises/_template/build.gradle +6 -0
- data/tracks/kotlin/exercises/accumulate/build.gradle +6 -0
- data/tracks/kotlin/exercises/accumulate/src/test/kotlin/AccumulateTest.kt +7 -0
- data/tracks/kotlin/exercises/acronym/build.gradle +6 -0
- data/tracks/kotlin/exercises/acronym/src/test/kotlin/AcronymTest.kt +7 -0
- data/tracks/kotlin/exercises/allergies/build.gradle +6 -0
- data/tracks/kotlin/exercises/allergies/src/test/kotlin/AllergiesTest.kt +20 -0
- data/tracks/kotlin/exercises/anagram/build.gradle +6 -0
- data/tracks/kotlin/exercises/anagram/src/test/kotlin/AnagramTest.kt +11 -0
- data/tracks/kotlin/exercises/atbash-cipher/build.gradle +6 -0
- data/tracks/kotlin/exercises/atbash-cipher/src/test/kotlin/AtbashTest.kt +3 -0
- data/tracks/kotlin/exercises/beer-song/build.gradle +6 -0
- data/tracks/kotlin/exercises/beer-song/src/test/kotlin/BeerSongTest.kt +13 -0
- data/tracks/kotlin/exercises/binary-search/build.gradle +6 -0
- data/tracks/kotlin/exercises/binary-search/src/test/kotlin/BinarySearchTest.kt +9 -0
- data/tracks/kotlin/exercises/binary/build.gradle +6 -0
- data/tracks/kotlin/exercises/binary/src/test/kotlin/BinaryTest.kt +2 -0
- data/tracks/kotlin/exercises/bob/build.gradle +6 -0
- data/tracks/kotlin/exercises/bob/src/test/kotlin/BobTest.kt +19 -0
- data/tracks/kotlin/exercises/bracket-push/build.gradle +6 -0
- data/tracks/kotlin/exercises/bracket-push/src/test/kotlin/BracketPushTest.kt +2 -0
- data/tracks/kotlin/exercises/build.gradle +17 -1
- data/tracks/kotlin/exercises/change/build.gradle +6 -0
- data/tracks/kotlin/exercises/change/src/test/kotlin/ChangeTest.kt +9 -0
- data/tracks/kotlin/exercises/difference-of-squares/build.gradle +6 -0
- data/tracks/kotlin/exercises/difference-of-squares/src/test/kotlin/SquaresTest.kt +13 -1
- data/tracks/kotlin/exercises/etl/build.gradle +6 -0
- data/tracks/kotlin/exercises/etl/src/test/kotlin/ETLTest.kt +5 -0
- data/tracks/kotlin/exercises/flatten-array/build.gradle +6 -0
- data/tracks/kotlin/exercises/flatten-array/src/test/kotlin/FlattenerTest.kt +9 -1
- data/tracks/kotlin/exercises/gigasecond/build.gradle +6 -0
- data/tracks/kotlin/exercises/gigasecond/src/test/kotlin/GigasecondTest.kt +6 -0
- data/tracks/kotlin/exercises/grade-school/build.gradle +6 -0
- data/tracks/kotlin/exercises/grade-school/src/test/kotlin/SchoolTest.kt +8 -0
- data/tracks/kotlin/exercises/hamming/build.gradle +6 -0
- data/tracks/kotlin/exercises/hamming/src/test/kotlin/HammingTest.kt +10 -0
- data/tracks/kotlin/exercises/hello-world/build.gradle +6 -0
- data/tracks/kotlin/exercises/hello-world/src/test/kotlin/HelloWorldTest.kt +6 -0
- data/tracks/kotlin/exercises/hexadecimal/build.gradle +6 -0
- data/tracks/kotlin/exercises/hexadecimal/src/test/kotlin/HexadecimalTest.kt +2 -0
- data/tracks/kotlin/exercises/isogram/build.gradle +6 -0
- data/tracks/kotlin/exercises/isogram/src/test/kotlin/IsogramTest.kt +2 -0
- data/tracks/kotlin/exercises/largest-series-product/build.gradle +6 -0
- data/tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt +5 -0
- data/tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesValidInputTest.kt +2 -0
- data/tracks/kotlin/exercises/leap/build.gradle +6 -0
- data/tracks/kotlin/exercises/leap/src/test/kotlin/LeapTest.kt +8 -0
- data/tracks/kotlin/exercises/linked-list/build.gradle +6 -0
- data/tracks/kotlin/exercises/linked-list/src/test/kotlin/DequeTest.kt +6 -0
- data/tracks/kotlin/exercises/luhn/build.gradle +6 -0
- data/tracks/kotlin/exercises/luhn/src/test/kotlin/LuhnTest.kt +11 -0
- data/tracks/kotlin/exercises/nth-prime/build.gradle +6 -0
- data/tracks/kotlin/exercises/nth-prime/src/test/kotlin/PrimeTest.kt +6 -0
- data/tracks/kotlin/exercises/nucleotide-count/build.gradle +6 -0
- data/tracks/kotlin/exercises/nucleotide-count/src/test/kotlin/NucleotideTest.kt +12 -1
- data/tracks/kotlin/exercises/pangram/build.gradle +6 -0
- data/tracks/kotlin/exercises/pangram/src/test/kotlin/PangramTest.kt +11 -0
- data/tracks/kotlin/exercises/pascals-triangle/build.gradle +6 -0
- data/tracks/kotlin/exercises/pascals-triangle/src/test/kotlin/PascalsTriangleTest.kt +5 -0
- data/tracks/kotlin/exercises/phone-number/build.gradle +6 -0
- data/tracks/kotlin/exercises/phone-number/src/test/kotlin/PhoneNumberTest.kt +9 -0
- data/tracks/kotlin/exercises/pig-latin/build.gradle +6 -0
- data/tracks/kotlin/exercises/pig-latin/src/test/kotlin/PigLatinTest.kt +2 -0
- data/tracks/kotlin/exercises/raindrops/build.gradle +6 -0
- data/tracks/kotlin/exercises/raindrops/src/test/kotlin/RaindropsTest.kt +2 -0
- data/tracks/kotlin/exercises/rna-transcription/build.gradle +6 -0
- data/tracks/kotlin/exercises/rna-transcription/src/test/kotlin/RnaTranscriptionTest.kt +8 -1
- data/tracks/kotlin/exercises/robot-name/build.gradle +6 -0
- data/tracks/kotlin/exercises/robot-name/src/test/kotlin/RobotTest.kt +4 -0
- data/tracks/kotlin/exercises/roman-numerals/build.gradle +6 -0
- data/tracks/kotlin/exercises/roman-numerals/src/test/kotlin/RomanNumeralTest.kt +2 -0
- data/tracks/kotlin/exercises/scrabble-score/build.gradle +6 -0
- data/tracks/kotlin/exercises/scrabble-score/src/test/kotlin/ScrabbleScoreTest.kt +2 -0
- data/tracks/kotlin/exercises/series/build.gradle +6 -0
- data/tracks/kotlin/exercises/series/src/test/kotlin/SeriesTest.kt +4 -0
- data/tracks/kotlin/exercises/sieve/build.gradle +6 -0
- data/tracks/kotlin/exercises/sieve/src/test/kotlin/SieveTest.kt +4 -0
- data/tracks/kotlin/exercises/simple-cipher/build.gradle +6 -0
- data/tracks/kotlin/exercises/simple-cipher/src/test/kotlin/IncorrectKeyCipherTest.kt +6 -0
- data/tracks/kotlin/exercises/simple-cipher/src/test/kotlin/RandomKeyCipherTest.kt +7 -0
- data/tracks/kotlin/exercises/simple-cipher/src/test/kotlin/SubstitutionCipherTest.kt +9 -0
- data/tracks/kotlin/exercises/space-age/build.gradle +6 -0
- data/tracks/kotlin/exercises/space-age/src/test/kotlin/SpaceAgeTest.kt +10 -0
- data/tracks/kotlin/exercises/strain/build.gradle +6 -0
- data/tracks/kotlin/exercises/strain/src/test/kotlin/StrainTest.kt +13 -0
- data/tracks/kotlin/exercises/word-count/build.gradle +6 -0
- data/tracks/kotlin/exercises/word-count/src/test/kotlin/WordCountTest.kt +8 -0
- data/tracks/objective-c/circle.yml +1 -1
- data/tracks/perl6/.travis.yml +2 -2
- data/tracks/perl6/config.json +5 -0
- data/tracks/perl6/docs/TESTS.md +78 -18
- data/tracks/perl6/exercises/allergies/{Example.p6 → Example.pm} +0 -0
- data/tracks/perl6/exercises/allergies/allergies.t +2 -7
- data/tracks/perl6/exercises/atbash-cipher/{Example.p6 → Example.pm} +0 -0
- data/tracks/perl6/exercises/atbash-cipher/cipher.t +2 -7
- data/tracks/perl6/exercises/linked-list/Example.pm6 +51 -0
- data/tracks/perl6/exercises/linked-list/linked-list.t +91 -0
- data/tracks/perl6/exercises/space-age/{Example.p6 → Example.pm} +0 -0
- data/tracks/perl6/exercises/space-age/space-age.t +2 -7
- data/tracks/perl6/exercises/trinary/{Example.p6 → Example.pm} +0 -0
- data/tracks/perl6/exercises/trinary/trinary.t +2 -7
- data/tracks/perl6/exercises/wordy/{Example.p6 → Example.pm} +0 -0
- data/tracks/perl6/exercises/wordy/wordy.t +2 -7
- data/tracks/pony/README.md +4 -27
- data/tracks/pony/config.json +16 -0
- data/tracks/pony/exercises/atbash-cipher/example.pony +40 -0
- data/tracks/pony/exercises/atbash-cipher/test.pony +67 -0
- data/tracks/pony/exercises/beer-song/example.pony +44 -0
- data/tracks/pony/exercises/beer-song/test.pony +27 -0
- data/tracks/pony/exercises/rna-transcription/test.pony +1 -1
- data/tracks/prolog/docs/INSTALLATION.md +1 -1
- data/tracks/prolog/docs/TESTS.md +2 -2
- metadata +24 -8
@@ -1,4 +1,5 @@
|
|
1
1
|
import org.junit.Test
|
2
|
+
import org.junit.Ignore
|
2
3
|
import java.time.LocalDate
|
3
4
|
import java.time.LocalDateTime
|
4
5
|
import java.time.Month
|
@@ -6,6 +7,7 @@ import kotlin.test.assertEquals
|
|
6
7
|
|
7
8
|
class GigasecondTest {
|
8
9
|
|
10
|
+
|
9
11
|
@Test
|
10
12
|
fun modernTime() {
|
11
13
|
val gigaSecond = Gigasecond(LocalDate.of(2011, Month.APRIL, 25))
|
@@ -13,6 +15,7 @@ class GigasecondTest {
|
|
13
15
|
assertEquals(LocalDateTime.of(2043, Month.JANUARY, 1, 1, 46, 40), gigaSecond.date)
|
14
16
|
}
|
15
17
|
|
18
|
+
@Ignore
|
16
19
|
@Test
|
17
20
|
fun afterEpochTime() {
|
18
21
|
val gigaSecond = Gigasecond(LocalDate.of(1977, Month.JUNE, 13))
|
@@ -20,6 +23,7 @@ class GigasecondTest {
|
|
20
23
|
assertEquals(LocalDateTime.of(2009, Month.FEBRUARY, 19, 1, 46, 40), gigaSecond.date)
|
21
24
|
}
|
22
25
|
|
26
|
+
@Ignore
|
23
27
|
@Test
|
24
28
|
fun beforeEpochTime() {
|
25
29
|
val gigaSecond = Gigasecond(LocalDate.of(1959, Month.JULY, 19))
|
@@ -27,6 +31,7 @@ class GigasecondTest {
|
|
27
31
|
assertEquals(LocalDateTime.of(1991, Month.MARCH, 27, 1, 46, 40), gigaSecond.date)
|
28
32
|
}
|
29
33
|
|
34
|
+
@Ignore
|
30
35
|
@Test
|
31
36
|
fun withFullTimeSpecified() {
|
32
37
|
val gigaSecond = Gigasecond(LocalDateTime.of(2015, Month.JANUARY, 24, 22, 0, 0))
|
@@ -34,6 +39,7 @@ class GigasecondTest {
|
|
34
39
|
assertEquals(LocalDateTime.of(2046, Month.OCTOBER, 2, 23, 46, 40), gigaSecond.date)
|
35
40
|
}
|
36
41
|
|
42
|
+
@Ignore
|
37
43
|
@Test
|
38
44
|
fun withFullTimeSpecifiedAndDayRollover() {
|
39
45
|
val gigaSecond = Gigasecond(LocalDateTime.of(2015, Month.JANUARY, 24, 23, 59, 59))
|
@@ -1,5 +1,6 @@
|
|
1
1
|
import org.junit.Before
|
2
2
|
import org.junit.Test
|
3
|
+
import org.junit.Ignore
|
3
4
|
import kotlin.test.assertEquals
|
4
5
|
import kotlin.test.assertTrue
|
5
6
|
|
@@ -12,11 +13,13 @@ class SchoolTest {
|
|
12
13
|
school = School()
|
13
14
|
}
|
14
15
|
|
16
|
+
|
15
17
|
@Test
|
16
18
|
fun startsWithNoStudents() {
|
17
19
|
assertTrue(school.db().isEmpty())
|
18
20
|
}
|
19
21
|
|
22
|
+
@Ignore
|
20
23
|
@Test
|
21
24
|
fun addsStudents() {
|
22
25
|
school.add("Aimee", 2)
|
@@ -25,6 +28,7 @@ class SchoolTest {
|
|
25
28
|
assertEquals(expected, school.db())
|
26
29
|
}
|
27
30
|
|
31
|
+
@Ignore
|
28
32
|
@Test
|
29
33
|
fun addsMoreStudentsInSameGrade() {
|
30
34
|
val grade = 2
|
@@ -36,6 +40,7 @@ class SchoolTest {
|
|
36
40
|
assertEquals(expected, school.db())
|
37
41
|
}
|
38
42
|
|
43
|
+
@Ignore
|
39
44
|
@Test
|
40
45
|
fun addsStudentsInMultipleGrades() {
|
41
46
|
school.add("Chelsea", 3)
|
@@ -45,6 +50,7 @@ class SchoolTest {
|
|
45
50
|
assertEquals(expected, school.db())
|
46
51
|
}
|
47
52
|
|
53
|
+
@Ignore
|
48
54
|
@Test
|
49
55
|
fun getsStudentsInAGrade() {
|
50
56
|
school.add("Franklin", 5)
|
@@ -55,11 +61,13 @@ class SchoolTest {
|
|
55
61
|
assertEquals(expected, school.db())
|
56
62
|
}
|
57
63
|
|
64
|
+
@Ignore
|
58
65
|
@Test
|
59
66
|
fun getsStudentsInEmptyGrade() {
|
60
67
|
assertTrue(school.grade(1).isEmpty())
|
61
68
|
}
|
62
69
|
|
70
|
+
@Ignore
|
63
71
|
@Test
|
64
72
|
fun sortsSchool() {
|
65
73
|
school.add("Jennifer", 4)
|
@@ -1,48 +1,58 @@
|
|
1
1
|
import org.junit.Test
|
2
|
+
import org.junit.Ignore
|
2
3
|
import kotlin.test.assertEquals
|
3
4
|
|
4
5
|
class HammingTest {
|
5
6
|
|
7
|
+
|
6
8
|
@Test
|
7
9
|
fun noDifferenceBetweenIdenticalStrands() {
|
8
10
|
assertEquals(0, Hamming.compute("A", "A"))
|
9
11
|
}
|
10
12
|
|
13
|
+
@Ignore
|
11
14
|
@Test
|
12
15
|
fun completeHammingDistanceOfForSingleNucleotideStrand() {
|
13
16
|
assertEquals(1, Hamming.compute("A", "G"))
|
14
17
|
}
|
15
18
|
|
19
|
+
@Ignore
|
16
20
|
@Test
|
17
21
|
fun completeHammingDistanceForSmallStrand() {
|
18
22
|
assertEquals(2, Hamming.compute("AG", "CT"))
|
19
23
|
}
|
20
24
|
|
25
|
+
@Ignore
|
21
26
|
@Test
|
22
27
|
fun smallHammingDistance() {
|
23
28
|
assertEquals(1, Hamming.compute("AT", "CT"))
|
24
29
|
}
|
25
30
|
|
31
|
+
@Ignore
|
26
32
|
@Test
|
27
33
|
fun smallHammingDistanceInLongerStrand() {
|
28
34
|
assertEquals(1, Hamming.compute("GGACG", "GGTCG"))
|
29
35
|
}
|
30
36
|
|
37
|
+
@Ignore
|
31
38
|
@Test(expected = IllegalArgumentException::class)
|
32
39
|
fun validatesFirstStrandNotLonger() {
|
33
40
|
Hamming.compute("AAAG", "AAA")
|
34
41
|
}
|
35
42
|
|
43
|
+
@Ignore
|
36
44
|
@Test(expected = IllegalArgumentException::class)
|
37
45
|
fun validatesOtherStrandNotLonger() {
|
38
46
|
Hamming.compute("AAA", "AAAG")
|
39
47
|
}
|
40
48
|
|
49
|
+
@Ignore
|
41
50
|
@Test
|
42
51
|
fun largeHammingDistance() {
|
43
52
|
assertEquals(4, Hamming.compute("GATACA", "GCATAA"))
|
44
53
|
}
|
45
54
|
|
55
|
+
@Ignore
|
46
56
|
@Test
|
47
57
|
fun hammingDistanceInVeryLongStrand() {
|
48
58
|
assertEquals(9, Hamming.compute("GGACGGATTCTG", "AGGACGGATTCT"))
|
@@ -1,30 +1,36 @@
|
|
1
1
|
import kotlin.test.assertEquals
|
2
2
|
import org.junit.Test
|
3
|
+
import org.junit.Ignore
|
3
4
|
|
4
5
|
class HelloWorldTest {
|
5
6
|
|
7
|
+
|
6
8
|
@Test
|
7
9
|
fun helloNoName() {
|
8
10
|
assertEquals("Hello, World!", HelloWorld.hello())
|
9
11
|
}
|
10
12
|
|
13
|
+
@Ignore
|
11
14
|
@Test
|
12
15
|
fun helloBlankName() {
|
13
16
|
assertEquals("Hello, World!", HelloWorld.hello(""))
|
14
17
|
assertEquals("Hello, World!", HelloWorld.hello(" "))
|
15
18
|
}
|
16
19
|
|
20
|
+
@Ignore
|
17
21
|
@Test
|
18
22
|
fun helloNullName() {
|
19
23
|
//This isn't advised in Kotlin but demonstrates the null safety in Kotlin
|
20
24
|
assertEquals("Hello, World!", HelloWorld.hello(null))
|
21
25
|
}
|
22
26
|
|
27
|
+
@Ignore
|
23
28
|
@Test
|
24
29
|
fun helloSampleName() {
|
25
30
|
assertEquals("Hello, Alice!", HelloWorld.hello("Alice"))
|
26
31
|
}
|
27
32
|
|
33
|
+
@Ignore
|
28
34
|
@Test
|
29
35
|
fun helloAnotherSampleName() {
|
30
36
|
assertEquals("Hello, Bob!", HelloWorld.hello("Bob"))
|
@@ -1,4 +1,5 @@
|
|
1
1
|
import org.junit.Test
|
2
|
+
import org.junit.Ignore
|
2
3
|
import org.junit.runner.RunWith
|
3
4
|
import org.junit.runners.Parameterized
|
4
5
|
import kotlin.test.assertEquals
|
@@ -28,6 +29,7 @@ class HexadecimalTest(val input: String, val expectedOutput: Int) {
|
|
28
29
|
)
|
29
30
|
}
|
30
31
|
|
32
|
+
|
31
33
|
@Test
|
32
34
|
fun hexStringToInt() {
|
33
35
|
assertEquals(expectedOutput, Hexadecimal.toDecimal(input))
|
@@ -1,5 +1,6 @@
|
|
1
1
|
|
2
2
|
import org.junit.Test
|
3
|
+
import org.junit.Ignore
|
3
4
|
import org.junit.runner.RunWith
|
4
5
|
import org.junit.runners.Parameterized
|
5
6
|
import kotlin.test.assertEquals
|
@@ -24,6 +25,7 @@ class IsogramTest(val input: String, val expectedOutput: Boolean) {
|
|
24
25
|
)
|
25
26
|
}
|
26
27
|
|
28
|
+
|
27
29
|
@Test
|
28
30
|
fun test() {
|
29
31
|
assertEquals(expectedOutput, Isogram.isIsogram(input))
|
data/tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
CHANGED
@@ -1,23 +1,28 @@
|
|
1
1
|
|
2
2
|
import org.junit.Test
|
3
|
+
import org.junit.Ignore
|
3
4
|
|
4
5
|
class SeriesInvalidInputTest {
|
5
6
|
|
7
|
+
|
6
8
|
@Test(expected = IllegalArgumentException::class)
|
7
9
|
fun nonDigitCharacters() {
|
8
10
|
Series("1234a5")
|
9
11
|
}
|
10
12
|
|
13
|
+
@Ignore
|
11
14
|
@Test(expected = IllegalArgumentException::class)
|
12
15
|
fun negativeSpan() {
|
13
16
|
Series("12345").getLargestProduct(-1)
|
14
17
|
}
|
15
18
|
|
19
|
+
@Ignore
|
16
20
|
@Test(expected = IllegalArgumentException::class)
|
17
21
|
fun spanLargerThanStringSize() {
|
18
22
|
Series("123").getLargestProduct(4)
|
19
23
|
}
|
20
24
|
|
25
|
+
@Ignore
|
21
26
|
@Test(expected = IllegalArgumentException::class)
|
22
27
|
fun spanLargerThanStringSizeUsingEmptyString() {
|
23
28
|
Series("").getLargestProduct(1)
|
@@ -1,5 +1,6 @@
|
|
1
1
|
|
2
2
|
import org.junit.Test
|
3
|
+
import org.junit.Ignore
|
3
4
|
import org.junit.runner.RunWith
|
4
5
|
import org.junit.runners.Parameterized
|
5
6
|
import kotlin.test.assertEquals
|
@@ -25,6 +26,7 @@ class SeriesValidInputTest(val input: String, val span: Int, val expectedOutput:
|
|
25
26
|
)
|
26
27
|
}
|
27
28
|
|
29
|
+
|
28
30
|
@Test
|
29
31
|
fun validInputTest() {
|
30
32
|
assertEquals(expectedOutput, Series(input).getLargestProduct(span))
|
@@ -1,39 +1,47 @@
|
|
1
1
|
import org.junit.Test
|
2
|
+
import org.junit.Ignore
|
2
3
|
import kotlin.test.assertFalse
|
3
4
|
import kotlin.test.assertTrue
|
4
5
|
|
5
6
|
class LeapTest {
|
6
7
|
|
8
|
+
|
7
9
|
@Test
|
8
10
|
fun leapYear() {
|
9
11
|
assertTrue(Year(1996).isLeap)
|
10
12
|
}
|
11
13
|
|
14
|
+
@Ignore
|
12
15
|
@Test
|
13
16
|
fun standardOddYear() {
|
14
17
|
assertFalse(Year(1997).isLeap)
|
15
18
|
}
|
16
19
|
|
20
|
+
@Ignore
|
17
21
|
@Test
|
18
22
|
fun standardEvenYear() {
|
19
23
|
assertFalse(Year(1998).isLeap)
|
20
24
|
}
|
21
25
|
|
26
|
+
@Ignore
|
22
27
|
@Test
|
23
28
|
fun standardNineteenthCentury() {
|
24
29
|
assertFalse(Year(1900).isLeap)
|
25
30
|
}
|
26
31
|
|
32
|
+
@Ignore
|
27
33
|
@Test
|
28
34
|
fun standardEighteenthCentury() {
|
29
35
|
assertFalse(Year(1800).isLeap)
|
30
36
|
}
|
31
37
|
|
38
|
+
@Ignore
|
32
39
|
@Test
|
33
40
|
fun leapTwentyFourthCentury() {
|
34
41
|
assertTrue(Year(2400).isLeap)
|
35
42
|
}
|
36
43
|
|
44
|
+
@Ignore
|
37
45
|
@Test
|
38
46
|
fun leapY2K() {
|
39
47
|
assertTrue(Year(2000).isLeap)
|
@@ -1,5 +1,6 @@
|
|
1
1
|
import org.junit.Before
|
2
2
|
import org.junit.Test
|
3
|
+
import org.junit.Ignore
|
3
4
|
import kotlin.test.assertEquals
|
4
5
|
|
5
6
|
class DequeTest {
|
@@ -10,6 +11,7 @@ class DequeTest {
|
|
10
11
|
subject = Deque()
|
11
12
|
}
|
12
13
|
|
14
|
+
|
13
15
|
@Test
|
14
16
|
fun pushPop() {
|
15
17
|
subject.push(10)
|
@@ -18,6 +20,7 @@ class DequeTest {
|
|
18
20
|
assertEquals(10, subject.pop())
|
19
21
|
}
|
20
22
|
|
23
|
+
@Ignore
|
21
24
|
@Test
|
22
25
|
fun pushShift() {
|
23
26
|
subject.push(10)
|
@@ -26,6 +29,7 @@ class DequeTest {
|
|
26
29
|
assertEquals(20, subject.shift())
|
27
30
|
}
|
28
31
|
|
32
|
+
@Ignore
|
29
33
|
@Test
|
30
34
|
fun unshiftShift() {
|
31
35
|
subject.unshift(10)
|
@@ -34,6 +38,7 @@ class DequeTest {
|
|
34
38
|
assertEquals(10, subject.shift())
|
35
39
|
}
|
36
40
|
|
41
|
+
@Ignore
|
37
42
|
@Test
|
38
43
|
fun unshiftPop() {
|
39
44
|
subject.unshift(10)
|
@@ -42,6 +47,7 @@ class DequeTest {
|
|
42
47
|
assertEquals(20, subject.pop())
|
43
48
|
}
|
44
49
|
|
50
|
+
@Ignore
|
45
51
|
@Test
|
46
52
|
fun example() {
|
47
53
|
subject.push(10)
|