Sha256: 212d350e499dbd6cfee9b4d07d018f7bf4924a8a3d7aeb927425d1028c674f5e

Contents?: true

Size: 601 Bytes

Versions: 89

Compression:

Stored size: 601 Bytes

Contents

import org.junit.Test

class SeriesInvalidInputTest {

    @Test(expected = IllegalArgumentException::class)
    fun nonDigitCharacters() {
        Series("1234a5")
    }

    @Test(expected = IllegalArgumentException::class)
    fun negativeSpan() {
        Series("12345").getLargestProduct(-1)
    }

    @Test(expected = IllegalArgumentException::class)
    fun spanLargerThanStringSize() {
        Series("123").getLargestProduct(4)
    }

    @Test(expected = IllegalArgumentException::class)
    fun spanLargerThanStringSizeUsingEmptyString() {
        Series("").getLargestProduct(1)
    }
}

Version data entries

89 entries across 89 versions & 1 rubygems

Version Path
trackler-2.0.6.33 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.32 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.31 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.30 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.29 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.28 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.27 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.26 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.25 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.24 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.23 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.22 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.21 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.20 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.19 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.18 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.17 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.16 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.15 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt
trackler-2.0.6.14 tracks/kotlin/exercises/largest-series-product/src/test/kotlin/SeriesInvalidInputTest.kt