git ssb

0+

cel-desktop / ssb-pkg



Tree: d456a6cc8589489e558e6164750474ed2cfc961e

Files: d456a6cc8589489e558e6164750474ed2cfc961e / test / test-50-path-as-buffer / test-x-index.js

557 bytesRaw
1'use strict';
2
3var fs = require('fs');
4var path = require('path');
5var hasURL = typeof URL !== 'undefined';
6
7var d = __dirname;
8var f = path.join(__dirname, 'test-z-asset.css');
9
10console.log(fs.statSync(f).size);
11console.log(fs.statSync(Buffer.from(f)).size);
12if (hasURL) console.log(fs.statSync(new URL('file://' + f)).size);
13
14console.log(fs.readdirSync(d).includes('test-z-asset.css'));
15console.log(fs.readdirSync(Buffer.from(d)).includes('test-z-asset.css'));
16if (hasURL) console.log(fs.readdirSync(new URL('file://' + d)).includes('test-z-asset.css'));
17

Built with git-ssb-web