Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore: update dependency @types/node to v22 #1404

Merged
merged 8 commits into from
Feb 12, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
"@types/figlet": "1.7.0",
"@types/jest": "29.5.14",
"@types/micromatch": "4.0.9",
"@types/node": "20.17.10",
"@types/node": "22.13.1",
"@types/semver": "7.5.8",
"@types/tar": "6.1.13",
"@types/unzipper": "0.10.10",
Expand Down
2 changes: 1 addition & 1 deletion src/types/files/archives/zip.ts
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ export default class Zip extends Archive {

// Finalize writing the zip file
await zipFile.finalize();
await new Promise((resolve) => {
await new Promise<void>((resolve) => {
// We are writing to a file, so we want to wait on the 'close' event which indicates the file
// descriptor has been closed. 'finished' will also fire before 'close' does.
writeStream.on('close', resolve);
Expand Down
23 changes: 10 additions & 13 deletions test/modules/candidates/candidateWriter.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,21 +53,18 @@ async function walkAndStat(dirPath: string): Promise<[string, Stats][]> {
if (!(await fsPoly.exists(dirPath))) {
return [];
}

return Promise.all(
(await fsPoly.walk(dirPath)).sort().map(async (filePath) => {
let stats: Stats;
try {
stats = await fs.promises.lstat(filePath);
// Hard-code properties that can change with file reads
stats.atime = new Date(0);
stats.atimeMs = 0;
// Hard-code properties that can change with hard-linking
stats.ctime = new Date(0);
stats.ctimeMs = 0;
stats.nlink = 0;
} catch {
stats = new Stats();
}
const stats = await fs.promises.lstat(filePath);
// Hard-code properties that can change with file reads
stats.atime = new Date(0);
stats.atimeMs = 0;
// Hard-code properties that can change with hard-linking
stats.ctime = new Date(0);
stats.ctimeMs = 0;
stats.nlink = 0;

return [filePath.replace(path.normalize(dirPath) + path.sep, ''), stats];
}),
);
Expand Down
Loading