MCPcopy Create free account
hub / github.com/DIYgod/RSSHub / writeFile

Function writeFile

lib/utils/directory-import.test.ts:11–14  ·  view source on GitHub ↗
(filePath: string, content: string)

Source from the content-addressed store, hash-verified

9const createTempDir = () => fs.mkdtempSync(path.join(os.tmpdir(), 'rsshub-dir-import-'));
10
11const writeFile = (filePath: string, content: string) => {
12 fs.mkdirSync(path.dirname(filePath), { recursive: true });
13 fs.writeFileSync(filePath, content, 'utf8');
14};
15
16describe('directory-import', () => {
17 let tempDir = '';

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected