import { toIncludeMultiple } from "https://deno.land/x/unitest@v1.0.0-beta.82/matcher/to_include_multiple.ts";
Use .toIncludeMultiple
when checking if a string
includes all of the given
substrings
import {
defineExpect,
not,
test,
toIncludeMultiple,
} from "https://deno.land/x/unitest@$VERSION/mod.ts";
const expect = defineExpect({
matcherMap: {
toIncludeMultiple,
},
modifierMap: {
not,
},
});
test("passes when value includes all substrings", () => {
expect("hello world").toIncludeMultiple(["world", "hello"]);
expect("hello world").not.toIncludeMultiple(["world", "hello", "bob"]);
});