Skip to content

Commit

Permalink
Stop using symbolic links in tests
Browse files Browse the repository at this point in the history
Symbolic links might not work in some environments in Windows.
  • Loading branch information
kentaroi committed Aug 13, 2024
1 parent 9eaad0a commit 58024b9
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions test/integration/_create-project-rev.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,7 @@ const sourceDir = path.join(__dirname, "fixtures", "eleventy-project-rev");
module.exports = function(projectName) {
let projectDir = path.join(__dirname, "fixtures", projectName);
fs.rmSync(projectDir, { recursive: true, force: true });
fs.mkdirSync(projectDir);

let names = fs.readdirSync(sourceDir);
names.forEach(name => {
fs.symlinkSync(path.join(sourceDir, name), path.join(projectDir, name));
});
fs.cpSync(sourceDir, projectDir, { recursive: true });

return projectDir;
};

0 comments on commit 58024b9

Please sign in to comment.