MCPcopy Create free account
hub / github.com/angular/components / writeFile

Function writeFile

src/cdk/schematics/testing/test-case-setup.ts:53–62  ·  view source on GitHub ↗
(filePath: string, content: string)

Source from the content-addressed store, hash-verified

51 };
52
53 function writeFile(filePath: string, content: string) {
54 // Update the temp file system host to reflect the changes in the real file system.
55 // This is still necessary since we depend on the real file system for parsing the
56 // TypeScript project.
57 if (hostTree.exists(filePath)) {
58 hostTree.overwrite(filePath, content);
59 } else {
60 hostTree.create(filePath, content);
61 }
62 }
63}
64
65export async function createTestCaseSetup(

Callers 2

createFileSystemTestAppFunction · 0.85
createTestCaseSetupFunction · 0.85

Calls 2

overwriteMethod · 0.80
createMethod · 0.45

Tested by

no test coverage detected