• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

scoverage / sbt-scoverage-samples / #60

08 Apr 2023 02:29AM CUT coverage: 71.963% (+7.3%) from 64.706%
#60

push

rolandtritsch
Even more time to shut down.

77 of 107 relevant lines covered (71.96%)

0.72 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

50.0
/src/main/scala/org/scoverage/samples/SimpleObject.scala
1
package org.scoverage.samples
2

3
import scala.concurrent.{ExecutionContext, Future}
4
import ExecutionContext.Implicits.global
5

6
object SimpleObject {
7

8
  private def getSomething = Future.successful(3)
1✔
9

10
  private def getOtherSomething = Future.successful(5)
×
11

12
  def method(input1: Boolean, input2: Boolean): Future[Option[Boolean]] = {
13
    for {
14
      b <-
1✔
15
        if (input1) getSomething
1✔
16
        else getOtherSomething // this else should not be covered
×
17
    } yield {
18
      if (input1 && input2) {
1✔
19
        Some(true)
1✔
20
      } else if (input1 && !input2) {
×
21
        Some(false) // this too
×
22
      } else {
23
        None // this too
×
24
      }
25
    }
26
  }
27

28
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc