Function: seedDirectory()
@termwright/test / seedDirectory
Function: seedDirectory()
Section titled “Function: seedDirectory()”seedDirectory(
directory,options): readonlystring[]
Defined in: test/src/seed.ts:54
Creates the declared files inside directory.
A template is copied first and the declared files are written over it, so a test can take a whole project as its starting point and change the one file it is about.
Parameters
Section titled “Parameters”directory
Section titled “directory”string
options
Section titled “options”Returns
Section titled “Returns”readonly string[]
Throws
Section titled “Throws”TypeError when a path would leave directory. A test that writes
outside its own directory is not isolated, and ../../.ssh/config is the
kind of typo that should stop a run rather than land somewhere real.