jeff-zucker/solid-file-client

test:https fail on NSS v5.6.6

Opened this issue · 6 comments

test:https fails on NSS v5.6.6 but succeeded on earlier version (? v5.6.4 on https://bourgeoa.bourgeoa.ga:8540)

Running tests with prefix: https://
Error while generating items within TestFolderGenerator.generate
Couldn't create https://bourgeoa.bourgeoa.ga:8560/public/test-fc/test-folder/
FetchError [SFCFetchError]: SFCFetchError 500 https://bourgeoa.bourgeoa.ga:8560/public/test-fc/ - An internal server error occured
    at assertResponseOk (/home/alain/github/bourgeoa/solid-file-client/src/utils/errorUtils.js:190:11)
    at processTicksAndRejections (internal/process/task_queues.js:97:5) {
  successful: [],
  rejected: [
    Response {
      size: 0,
      timeout: 0,
      [Symbol(Body internals)]: [Object],
      [Symbol(Response internals)]: [Object]
    }
  ],
  rejectedErrors: [
    SingleResponseError: 500 https://bourgeoa.bourgeoa.ga:8560/public/test-fc/ - An internal server error occured
        at assertResponseOk (/home/alain/github/bourgeoa/solid-file-client/src/utils/errorUtils.js:189:61)
        at processTicksAndRejections (internal/process/task_queues.js:97:5) {
      response: [Response],
      ok: false,
      status: 500,
      statusText: 'Internal Server Error',
      url: 'https://bourgeoa.bourgeoa.ga:8560/public/test-fc/'
    }
  ],
  errors: [],
  ok: false,
  status: 500,
  statusText: 'Internal Server Error'
}
Please check the createFolder/createFile method for errors
Trace
    at Folder._callee4$ (/home/alain/github/bourgeoa/solid-file-client/tests/utils/TestFolderGenerator.js:383:25)
    at tryCatch (/home/alain/github/bourgeoa/solid-file-client/node_modules/regenerator-runtime/runtime.js:63:40)
    at Generator.invoke [as _invoke] (/home/alain/github/bourgeoa/solid-file-client/node_modules/regenerator-runtime/runtime.js:293:22)
    at Generator.throw (/home/alain/github/bourgeoa/solid-file-client/node_modules/regenerator-runtime/runtime.js:118:21)
    at asyncGeneratorStep (/home/alain/github/bourgeoa/solid-file-client/node_modules/@babel/runtime/helpers/asyncToGenerator.js:3:24)
    at _throw (/home/alain/github/bourgeoa/solid-file-client/node_modules/@babel/runtime/helpers/asyncToGenerator.js:29:9)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
Error in setup.js: Couldn't reset test-folder
SFCFetchError: SFCFetchError 500 https://bourgeoa.bourgeoa.ga:8560/public/test-fc/ - An internal server error occured
    at assertResponseOk (/home/alain/github/bourgeoa/solid-file-client/src/utils/errorUtils.js:190:11)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)

Can you show what s-file-client method caused this? Was it perhaps because no content-type was set? If so, see #203

@bourgeoa - Please specify which version of @solid-rest you are using for each test, since at the moment I'm trying to debug it and can't tell if the bug you found is related or not.

  • Yes. I shall specify.
  • This error occurs on node-auth-client v1.22 and v2.0.6
    It occurs at tests initialization. Test do not run at all

Thanks. Ouch.

I find the test output for solid-file-client completely unhelpful. There is no way to tell which part of multi-operation methods failed. There is no way to see what content was failed on. Do you find the test output in any way helpful?

For exampe, I am getting lots of this error, and I don't have the slightest idea of which part of copyFolder() failed.

  ● nested methods › copy › copyFolder › resolves with 201 and copies folder with depth 1 including its contents

    expect(received).toHaveProperty(path, value)

    Expected path: "url"

    Expected value: "file:///home/jeff/Dropbox/Web/solid/solid-file-client/v2/test-folder/SolidApi-composed/delete/parent/"
    Received value: ""

      401 |           const responses = await api.copyFolder(childOne.url, folderPlaceholder.url)
      402 |           expect(responses).toHaveLength(childOne.contents.length + 1)
    > 403 |           expect(responses[0]).toHaveProperty('url', apiUtils.getParentUrl(folderPlaceholder.url))
          |                                ^
      404 |           expect(responses[0]).toHaveProperty('status', 201)
      405 | 
      406 |           await expect(api.itemExists(folderPlaceholder.url)).resolves.toBe(true)

      at _callee27$ (tests/SolidApi.composed.test.js:403:32)

The SFCFetch errors are no better. I get "SFCFetchError Invalid URL: .meta" during copyFolder and no indication of which part of the process failed.