Sha256: e6c4dac4b7db78a91eefe377d82df69637d85a662b4e9f2acd1a1d3c9e6e5d5a
Contents?: true
Size: 899 Bytes
Versions: 55
Compression:
Stored size: 899 Bytes
Contents
describe("toContain", function() { it("delegates to j$.matchersUtil.contains", function() { var util = { contains: jasmine.createSpy('delegated-contains').and.returnValue(true) }, matcher = j$.matchers.toContain(util), result; result = matcher.compare("ABC", "B"); expect(util.contains).toHaveBeenCalledWith("ABC", "B", []); expect(result.pass).toBe(true); }); it("delegates to j$.matchersUtil.contains, passing in equality testers if present", function() { var util = { contains: jasmine.createSpy('delegated-contains').and.returnValue(true) }, customEqualityTesters = ['a', 'b'], matcher = j$.matchers.toContain(util, customEqualityTesters), result; result = matcher.compare("ABC", "B"); expect(util.contains).toHaveBeenCalledWith("ABC", "B", ['a', 'b']); expect(result.pass).toBe(true); }); });
Version data entries
55 entries across 55 versions & 4 rubygems