loadUrl enhancements (#134)
`loadUrl` enhancements - Make `options` parameter optional - Allow partial overriding of instance options when calling `loadUrl` directly - Make `requestOptions` optional - Document `loadUrl` usage and provide examples
This commit was merged in pull request #134.
This commit is contained in:
17
tests/lib/util/clone.js
Normal file
17
tests/lib/util/clone.js
Normal file
@@ -0,0 +1,17 @@
|
||||
var tape = require("tape")
|
||||
|
||||
var clone = require("../../../lib/util/clone")
|
||||
|
||||
tape("test clone method", function(t) {
|
||||
var obj = {one: 1, two: 2}
|
||||
var cloned = clone(obj)
|
||||
|
||||
t.notEqual(obj, cloned, "cloned object isn't the original object")
|
||||
|
||||
t.same(obj, cloned, "cloned object has the same values as original object")
|
||||
|
||||
cloned.three = 3
|
||||
t.notSame(obj, cloned, "modified cloned object doesn't have the same values as original object")
|
||||
|
||||
t.end()
|
||||
})
|
||||
Reference in New Issue
Block a user