Skip to content

Instantly share code, notes, and snippets.

@melvincarvalho
Created May 11, 2017 14:31
Show Gist options
  • Save melvincarvalho/2f239d53ba2655c6d1eb1c23f3a1c74e to your computer and use it in GitHub Desktop.
Save melvincarvalho/2f239d53ba2655c6d1eb1c23f3a1c74e to your computer and use it in GitHub Desktop.
node solid server tests all
1) AccountManager (account creation tests) accessing accounts should be able to access public file of an account:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
2) AccountManager (account creation tests) accessing accounts should get 404 if root does not exist:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
3) AccountManager (account creation tests) generating a certificate should generate a certificate if spkac is valid:
TypeError: Cannot read property 'header' of undefined
at Test._assertHeader (node_modules/supertest/lib/test.js:208:19)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
4) AccountManager (account creation tests) generating a certificate should not generate a certificate if spkac is not valid:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
5) AccountManager (account creation tests) creating an account with POST should not create WebID if no username is given:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
6) AccountManager (account creation tests) creating an account with POST should not create a WebID if it already exists:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
7) AccountManager (account creation tests) creating an account with POST should create the default folders:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
8) AccountManager (account creation tests) creating an account with POST should link WebID to the root account:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
9) AccountManager (account creation tests) creating an account with POST should create a private settings container:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
10) AccountManager (account creation tests) creating an account with POST should create a private prefs file in the settings container:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
11) AccountManager (account creation tests) creating an account with POST should create a private inbox container:
TypeError: Cannot read property 'status' of undefined
at Test._assertStatus (node_modules/supertest/lib/test.js:229:10)
at Test._assertFunction (node_modules/supertest/lib/test.js:247:11)
at Test.assert (node_modules/supertest/lib/test.js:148:18)
at assert (node_modules/supertest/lib/test.js:127:12)
at node_modules/supertest/lib/test.js:124:5
at Test.Request.callback (node_modules/superagent/lib/node/index.js:687:12)
at ClientRequest.<anonymous> (node_modules/superagent/lib/node/index.js:639:10)
at TLSSocket.socketErrorListener (_http_client.js:306:9)
at connectErrorNT (net.js:1015:8)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
12) Accounts API "before all" hook:
Uncaught Error: listen EADDRINUSE :::5001
at Object.exports._errnoException (util.js:949:11)
at exports._exceptionWithHostPort (util.js:972:20)
at Server._listen2 (net.js:1253:14)
at listen (net.js:1289:10)
at Server.listen (net.js:1385:5)
at parallel (test/api-accounts.js:60:28)
at node_modules/run-parallel/index.js:41:7
at Array.forEach (native)
at module.exports (node_modules/run-parallel/index.js:40:11)
at Context.<anonymous> (test/api-accounts.js:54:5)
13) HTTP APIs GET API should have glob support:
Uncaught TypeError: Cannot read property 'uri' of undefined
at Object.serialize (node_modules/rdflib/lib/serialize.js:14:24)
at lib/handlers/get.js:12:1150
at node_modules/async/lib/async.js:52:16
at done (node_modules/async/lib/async.js:246:17)
at node_modules/async/lib/async.js:44:16
at lib/handlers/get.js:12:1061
at aclAllow (lib/handlers/get.js:13:411)
at lib/handlers/get.js:12:566
at tryToString (fs.js:449:3)
at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:436:12)
14) PATCH nothing should change with empty patch:
Uncaught AssertionError: expected '@prefix : </emptyExample.ttl#>.\n\n:current :temp 123 .\n\n' to equal '\n <#current> <#temp> 123 .\n'
at Test.<anonymous> (test/patch-2.js:188:16)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
15) PATCH DELETE reproduce index 1 bug from pad:
Uncaught AssertionError: expected '@prefix : </existingTriple.ttl#>.\n@prefix dc: <http://purl.org/dc/elements/1.1/>.\n@prefix c: <https://www.w3.org/People/Berners-Lee/card#>.\n@prefix n: <http://rdfs.org/sioc/ns#>.\n@prefix p: <http://www.w3.org/ns/pim/pad#>.\n@prefix ic: <http://www.w3.org/2002/12/cal/ical#>.\n@prefix XML: <http://www.w3.org/2001/XMLSchema#>.\n@prefix flow: <http://www.w3.org/2005/01/wf/flow#>.\n@prefix ui: <http://www.w3.org/ns/ui#>.\n@prefix ind: </parent/index.ttl#>.\n@prefix mee: <http://www.w3.org/ns/pim/meeting#>.\n\n:id1477502276660 dc:author c:i; n:content ""; p:next :this.\n\n:id1477522707481\n ic:dtstart "2016-10-26T22:58:27Z"^^XML:dateTime;\n flow:participant c:i;\n ui:backgroundColor "#c1d0c8".\n:this\n a p:Notepad;\n dc:author c:i;\n dc:created "2016-10-25T15:44:42Z"^^XML:dateTime;\n dc:title "Shared Notes";\n p:next :id1477502276660.\nind:this flow:participation :id1477522707481; mee:sharedNotes :this.\n\n' to equal '@prefix dc: <http://purl.org/dc/elements/1.1/>.\n@prefix meeting: <http://www.w3.org/ns/pim/meeting#>.\n@prefix card: <https://www.w3.org/People/Berners-Lee/card#>.\n@prefix xsd: <http://www.w3.org/2001/XMLSchema#>.\n@prefix p: <http://www.w3.org/ns/pim/pad#>.\n@prefix in: </parent/index.ttl#>.\n@prefix n: <http://rdfs.org/sioc/ns#>.\n@prefix flow: <http://www.w3.org/2005/01/wf/flow#>.\n@prefix ic: <http://www.w3.org/2002/12/cal/ical#>.\n@prefix ui: <http://www.w3.org/ns/ui#>.\n\n<#this>\n dc:author\n card:i;\n dc:created\n "2016-10-25T15:44:42Z"^^xsd:dateTime;\n dc:title\n "Shared Notes";\n a p:Notepad;\n p:next\n <#id1477502276660>.\n in:this flow:participation <#id1477522707481>; meeting:sharedNotes <#this> .\n <#id1477502276660> dc:author card:i; n:content ""; p:next <#this> .\n<#id1477522707481>\n ic:dtstart\n "2016-10-26T22:58:27Z"^^xsd:dateTime;\n flow:participant\n card:i;\n ui:backgroundColor\n "#c1d0c8".\n'
at Test.<anonymous> (test/patch-2.js:82:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
16) PATCH DELETE and INSERT should be update a resource using SPARQL-query using `prefix`:
Uncaught AssertionError: expected '@prefix : </prefixSparql.ttl#>.\n@prefix schema: <http://schema.org/>.\n@prefix pro: <http://ogp.me/ns/profile#>.\n\n: a schema:Person; pro:first_name "Timothy".\n\n' to equal '@prefix schema: <http://schema.org/>.\n@prefix profile: <http://ogp.me/ns/profile#>.\n\n <#> profile:first_name "Timothy"; a schema:Person .\n'
at Test.<anonymous> (test/patch-2.js:110:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
17) PATCH INSERT should add a new triple:
Uncaught AssertionError: expected '@prefix : </addingTriple.ttl#>.\n\n:current :temp 123 .\n\n:test :hello 456 .\n\n' to equal '\n <#current> <#temp> 123 .\n <#test> <#hello> 456 .\n'
at Test.<anonymous> (test/patch-2.js:132:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
18) PATCH INSERT should add value to existing triple:
Uncaught AssertionError: expected '@prefix : </addingTripleValue.ttl#>.\n\n:current :temp 123, 456 .\n\n' to equal '\n <#current> <#temp> 123, 456 .\n'
at Test.<anonymous> (test/patch-2.js:151:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
19) PATCH INSERT should add value to same subject:
Uncaught AssertionError: expected '@prefix : </addingTripleSubj.ttl#>.\n\n:current :temp 123; :temp2 456 .\n\n' to equal '\n <#current> <#temp2> 456; <#temp> 123 .\n'
at Test.<anonymous> (test/patch-2.js:169:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
20) PATCH should create a new file if file does not exist:
Uncaught AssertionError: expected '@prefix : </notExisting.ttl#>.\n\n:test :hello 456 .\n\n' to equal '\n <#test> <#hello> 456 .\n'
at Test.<anonymous> (test/patch.js:27:16)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
21) PATCH nothing should change with empty patch:
Uncaught AssertionError: expected '@prefix : </emptyExample.ttl#>.\n\n:current :temp 123 .\n\n' to equal '\n <#current> <#temp> 123 .\n'
at Test.<anonymous> (test/patch.js:151:16)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
22) PATCH DELETE should be an empty resource if last triple is deleted:
Uncaught AssertionError: expected '@prefix : </existingTriple.ttl#>.\n\n' to equal '\n'
at Test.<anonymous> (test/patch.js:45:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
23) PATCH DELETE and INSERT should be update a resource using SPARQL-query using `prefix`:
Uncaught AssertionError: expected '@prefix : </prefixSparql.ttl#>.\n@prefix schema: <http://schema.org/>.\n@prefix pro: <http://ogp.me/ns/profile#>.\n\n: a schema:Person; pro:first_name "Timothy".\n\n' to equal '@prefix schema: <http://schema.org/>.\n@prefix profile: <http://ogp.me/ns/profile#>.\n\n <#> profile:first_name "Timothy"; a schema:Person .\n'
at Test.<anonymous> (test/patch.js:73:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
24) PATCH INSERT should add a new triple:
Uncaught AssertionError: expected '@prefix : </addingTriple.ttl#>.\n\n:current :temp 123 .\n\n:test :hello 456 .\n\n' to equal '\n <#current> <#temp> 123 .\n <#test> <#hello> 456 .\n'
at Test.<anonymous> (test/patch.js:95:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
25) PATCH INSERT should add value to existing triple:
Uncaught AssertionError: expected '@prefix : </addingTripleValue.ttl#>.\n\n:current :temp 123, 456 .\n\n' to equal '\n <#current> <#temp> 123, 456 .\n'
at Test.<anonymous> (test/patch.js:114:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
26) PATCH INSERT should add value to same subject:
Uncaught AssertionError: expected '@prefix : </addingTripleSubj.ttl#>.\n\n:current :temp 123; :temp2 456 .\n\n' to equal '\n <#current> <#temp2> 456; <#temp> 123 .\n'
at Test.<anonymous> (test/patch.js:132:18)
at Test.assert (node_modules/supertest/lib/test.js:156:6)
at Server.assert (node_modules/supertest/lib/test.js:127:12)
at emitCloseNT (net.js:1549:8)
at _combinedTickCallback (internal/process/next_tick.js:71:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment