Created
March 24, 2017 15:41
-
-
Save dimitarg/ff35702ee2b1efa9cdabc1de2c776348 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//@flow | |
declare var test: any | |
declare var expect: any | |
import {Seq} from "immutable" | |
test("hmmm", () => { | |
const xs : Seq<number, string> = Seq.of("a", "b", "c") | |
// this does not typecheck, map not found in Seq | |
const ys : Seq<number, string> = xs.map(x => x + x) | |
// map is in fact in seq, the following assertion passes | |
expect(ys.toJS()).toEqual(["aa", "bb", "cc"]) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment