Skip to content

assertFileNotIncludes

Assert that a file does not include a given substring.

import { assertFileNotIncludes } from "@kensio/smartass";
const filePath = "foobar.txt";
assertFileNotIncludes(filePath, "find me");
// This validates file contents at runtime without changing the path type.

Source file: src/assert/file-not-includes/file-not-includes.assert.ts