Sha256: aa023e1b5463eafeb4b12d16064c8cea496fcc589dad4971b51e89978bb78277

Contents?: true

Size: 1.78 KB

Versions: 3

Compression:

Stored size: 1.78 KB

Contents

/*
 * Calculate breakpoint query
 */
@include describe("[function] calc-breakpoint") {

    @include it("should expect breakpoint of passed key") {
        @include should(expect(
            flint-calc-breakpoint("alias", "desktop", 1)),
            to(be(80em))
        );
        @include should(expect(
            flint-calc-breakpoint("alias", "laptop", 2)),
            to(be(60em))
        );
        @include should(expect(
            flint-calc-breakpoint("alias", "tablet", 3)),
            to(be(40em))
        );
        @include should(expect(
            flint-calc-breakpoint("alias", "mobile", 4)),
            to(be(20em))
        );
    }

    @include it("should expect next breakpoint down from passed key") {
        @include should(expect(
            flint-calc-breakpoint("next", "desktop", 1)),
            to(be(60em))
        );
        @include should(expect(
            flint-calc-breakpoint("next", "laptop", 2)),
            to(be(40em))
        );
        @include should(expect(
            flint-calc-breakpoint("next", "tablet", 3)),
            to(be(20em))
        );
        @include should(expect(
            flint-calc-breakpoint("next", "mobile", 4)),
            to(be(0))
        );
    }

    @include it("should expect previous breakpoint up from passed key") {
        @include should(expect(
            flint-calc-breakpoint("prev", "desktop", 1)),
            to(be(80em))
        );
        @include should(expect(
            flint-calc-breakpoint("prev", "laptop", 2)),
            to(be(80em))
        );
        @include should(expect(
            flint-calc-breakpoint("prev", "tablet", 3)),
            to(be(60em))
        );
        @include should(expect(
            flint-calc-breakpoint("prev", "mobile", 4)),
            to(be(40em))
        );
    }
}

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
flint-gs-2.0.6 tests/input/functions/lib/_calc-breakpoint.scss
flint-gs-2.0.5 tests/input/functions/lib/_calc-breakpoint.scss
flint-gs-2.0.4 tests/input/functions/lib/_calc-breakpoint.scss