Ryan Dahl
9fd5e3c89c
Update tests to work with module contexts
15 years ago
Ryan Dahl
ba792ea202
:%s/sys.puts/console.log/g
and there was much rejoicing
15 years ago
Ben Noordhuis
c6c77d535f
Support for fstat(2) through fs.fstat() and fs.fstatSync(). Added test cases, updated documentation.
15 years ago
isaacs
5861db8a69
Remove process.mixin dependency from all tests.
15 years ago
Felix Geisendörfer
44dde5f24c
Remove fs/path globals from test suite
It is way too easy to not notice bugs due to those modules being
exported as globals while running the test suite.
See: http://github.com/ry/node/issues#issue/75
15 years ago
arlolra
04fac19822
Split tests.
15 years ago
isaacs
9acc8a686a
Expose fs.lstat
15 years ago
Ryan Dahl
ef55324f1a
Do not use Promise in 'fs' module
15 years ago
Ryan Dahl
b82ef28d9d
Rename 'posix' module to 'fs'
15 years ago
Felix Geisendörfer
530328f12b
CommonJS testing for node.js
Refactored test suite to use the assert module for testing rather than
mjsunit.
15 years ago
Ryan Dahl
7a2e784ad7
Module refactor - almost CommonJS compatible now
API change summary:
* require("/sys.js") becomes require("sys")
* require("circle.js") becomes require("./circle")
* process.path.join() becomes require("path").join()
15 years ago
Ryan Dahl
ad0a4cefb8
Namespace EVERYTHING under process; introduce GLOBAL
http://groups.google.com/group/nodejs/browse_thread/thread/1034fd2ad2cd93e8
15 years ago
Ryan Dahl
3d8b14e6f7
node.fs.* moved into "/posix.js"
use require("/posix.js") to access them.
15 years ago
Ryan Dahl
8185e1fd25
Remove include() add node.mixin()
include() should not be used by libraries because it will pollute the global
namespace. To discourage this behavior and bring Node more in-line with
the current CommonJS module system, include() is removed.
Small scripts like unit tests often times do want to pollute the global
namespace for ease. To avoid the boiler plate code of
var x = require("/x.js");
var foo = x.foo;
var bar = x.bar;
The function node.mixin() is stolen from jQuery's jQuery.extend. So that it
can be written:
node.mixin(require("/x.js"));
Reference:
http://docs.jquery.com/Utilities/jQuery.extend
http://groups.google.com/group/nodejs/browse_thread/thread/f9ac83e5c11e7e87
15 years ago
Ryan Dahl
4b8f503fac
Move mjsunit.js to system module directory.
15 years ago
Ryan
241950c1df
Add isDirectory(), isFile(), isSocket(), ... methods to stats object.
Thanks to Felix Geisendörfer for the initial patch.
16 years ago
Ryan
723c7d9f7c
Replace onExit() with process.addListener("exit")
- Update documentation.
- Depreciation message for onExit().
16 years ago
Ryan
88ad880556
Add new test for node.fs.stat()
16 years ago