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

test: add test description to fs.readFile tests #17610

Closed
Closed
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
3 changes: 3 additions & 0 deletions test/parallel/test-fs-readfile-empty.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@

'use strict';
require('../common');

// Trivial test of fs.readFile on an empty file.

const assert = require('assert');
const fs = require('fs');
const fixtures = require('../common/fixtures');
Expand Down
3 changes: 3 additions & 0 deletions test/parallel/test-fs-readfile-error.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@

'use strict';
const common = require('../common');

// Test that fs.readFile fails correctly on a non-existent file.

// `fs.readFile('/')` does not fail on FreeBSD, because you can open and read
// the directory there.
if (common.isFreeBSD)
Expand Down
3 changes: 3 additions & 0 deletions test/parallel/test-fs-readfile-fd.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
'use strict';
require('../common');

// Test fs.readFile using a file descriptor.

const fixtures = require('../common/fixtures');
const assert = require('assert');
const fs = require('fs');
Expand Down
3 changes: 3 additions & 0 deletions test/parallel/test-fs-readfile-unlink.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@

'use strict';
const common = require('../common');

// Test that unlink succeeds immediately after readFile completes.

const assert = require('assert');
const fs = require('fs');
const path = require('path');
Expand Down
3 changes: 3 additions & 0 deletions test/parallel/test-fs-readfile-zero-byte-liar.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@

'use strict';
const common = require('../common');

// Test that readFile works even when stat returns size 0.

const assert = require('assert');
const fs = require('fs');

Expand Down