@import "../../stylesheets/functions/overlap_factor";
@include test("@function overlap_factor") {
  $__TESTS__: (
    "sinner extend": (
      20% 50% 100%: 30%,
      20% 50% 90%: 27%,
      20% 50% 80%: 24%,
      20% 50% 70%: 21%,
      20% 50% 60%: 18%,
      20% 50% 50%: 15%,
      20% 50% 40%: 12%,
      20% 50% 30%: 9%,
      20% 50% 20%: 6%,
      20% 50% 10%: 3%,
      20% 50% 0%: 0%,
    ),
    "sinner no room": (
      20% 20% 100%: 0%,
      20% 20% 50%: 0%,
      20% 20% 0%: 0%,
    ),
    "pillar extend": (
      30% 90% 100%: 60%,
      30% 90% 50%: 30%,
      30% 90% 0%: 0%,
    ),
  );

  @each $suite, $tests in $__TESTS__ {
    @each $args, $expect in $tests {
      @include assert-equal(
        overlap_factor(nth($args, 1), nth($args, 2), nth($args, 3)),
        $expect,
        $suite
      );
    }
  }
}
