Sha256: fc5a2a1d22e57669d34feade0dd1c820ff1b27468b92d2ab38cc4f6cb7611011

Contents?: true

Size: 1.19 KB

Versions: 24

Compression:

Stored size: 1.19 KB

Contents

import org.scalatest.{Matchers, FunSuite}

/** @version 1.0.0 */
class ArmstrongNumbersTest extends FunSuite with Matchers {

  test("Single digit numbers are Armstrong numbers") {
    ArmstrongNumbers.isArmstrongNumber(5) should be (true)
  }

  test("There are no 2 digit Armstrong numbers") {
    pending
    ArmstrongNumbers.isArmstrongNumber(10) should be (false)
  }

  test("Three digit number that is an Armstrong number") {
    pending
    ArmstrongNumbers.isArmstrongNumber(153) should be (true)
  }

  test("Three digit number that is not an Armstrong number") {
    pending
    ArmstrongNumbers.isArmstrongNumber(100) should be (false)
  }

  test("Four digit number that is an Armstrong number") {
    pending
    ArmstrongNumbers.isArmstrongNumber(9474) should be (true)
  }

  test("Four digit number that is not an Armstrong number") {
    pending
    ArmstrongNumbers.isArmstrongNumber(9475) should be (false)
  }

  test("Seven digit number that is an Armstrong number") {
    pending
    ArmstrongNumbers.isArmstrongNumber(9926315) should be (true)
  }

  test("Seven digit number that is not an Armstrong number") {
    pending
    ArmstrongNumbers.isArmstrongNumber(9926314) should be (false)
  }
}

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
trackler-2.2.1.180 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.179 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.178 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.177 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.176 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.175 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.174 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.173 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.172 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.171 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.170 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.169 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.167 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.166 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.165 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.164 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.163 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.162 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.161 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala
trackler-2.2.1.160 tracks/scala/exercises/armstrong-numbers/src/test/scala/ArmstrongNumbersTest.scala