Join our webinar on Wednesday, June 26, at 1pm EDTHow Chia Mitigates Risk in the Crypto Industry.Register
Socket
Socket
Sign inDemoInstall

ubivar

Package Overview
Dependencies
1
Maintainers
1
Versions
44
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.13-beta to 0.1.14-beta

test/data/addresses.js

2

package.json
{
"name": "ubivar",
"version": "0.1.13-beta",
"version": "0.1.14-beta",
"description": "API wrapper to Ubivar",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -13,3 +13,3 @@ module.exports = [{

, "cvc_check":"pass"
},"metadata":{
},"meta":{
"channel":"mobile_123"

@@ -28,4 +28,4 @@ }}, {

, "cvc_check":"pass"
},"metadata":{
},"meta":{
"channel":"mobile_234"
}}]

@@ -42,2 +42,3 @@ "use strict"

} else {
console.log(err, res)
done((new Error("Did not return an id")))

@@ -59,2 +60,3 @@ }

} else {
console.log(err, res)
done((new Error("Did not return an id")))

@@ -70,2 +72,3 @@ }

} else {
console.log(err, res)
done((new Error("Did not return the resource with id = "+idResource)))

@@ -91,5 +94,7 @@ }

} else {
console.log(err, sentData, newData)
done(new Error("Updated resource is not deep equal to submitted resource"))
}
} else {
console.log(err, res)
done(new Error("Non-200 status code, or data length !== 1 when updating"))

@@ -105,2 +110,3 @@ }

} else {
console.log(err, res)
done((new Error("Did not return the deleted resource with id = "+idResource)))

@@ -119,9 +125,18 @@ }

ubivar[resource].create(examples[0], function(err, res){
if(err) return done(err)
if(err) {
console.log(err)
return done(err)
}
ids.push(res.data[0].id)
ubivar[resource].create(examples[0], function(err, res){
if(err) return done(err)
if(err) {
console.log(err)
return done(err)
}
ids.push(res.data[0].id)
ubivar[resource].create(examples[0], function(err, res){
if(err) return done(err)
if(err) {
console.log(err)
return done(err)
}
ids.push(res.data[0].id)

@@ -137,5 +152,11 @@ done()

ubivar[resource].list({limit:nLimit}, function(err, res){
if(err) done(err)
else if(res.data.length === nLimit) done()
else done(new Error("Should 'limit' list to N="+nLimit+" resources"))
if(err) {
console.log(err, res)
done(err)
} else if(res.data.length === nLimit) {
done()
} else {
console.log(res)
done(new Error("Should 'limit' list to N="+nLimit+" resources"))
}
})

@@ -147,5 +168,11 @@ })

ubivar[resource].list({limit:nLimit}, function(err, res){
if(err) done(err)
else if(res.data.length === nLimit) done()
else done(new Error("Should 'limit' list to N="+nLimit+" resources"))
if(err) {
console.log(err)
done(err)
} else if(res.data.length === nLimit) {
done()
} else {
console.log(res)
done(new Error("Should 'limit' list to N="+nLimit+" resources"))
}
})

@@ -157,4 +184,10 @@ })

ubivar[resource].list({"start_after": ids[0], "limit":nLimit}, function(err, res){
if(err) return done(err)
if(res.data.length !== nLimit) return done(new Error("Should return N="+nLimit))
if(err){
console.log(err)
return done(err)
}
if(res.data.length !== nLimit){
console.log(res)
return done(new Error("Should return N="+nLimit))
}
var returnedIds = _.pluck(res.data, "id")

@@ -161,0 +194,0 @@ if(_.contains(returnedIds, ids[0])){

@@ -7,3 +7,3 @@ "use strict"

describe("Routing", function(){
xdescribe("Routing", function(){
it("Should return a valid routing resource", function(done){

@@ -10,0 +10,0 @@ ubivar.routing.list({"limit":"1"}, function(err, res){

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc