Testing TUS server implementations

Hey folks,

I’m relatively new to TUS but I ended up contributing some PRs to GitHub - edihasaj/tuspyserver and I wanted to ask the community for advice.

Specifically, I am looking for any test suite or Postman collection to helping me test the server is functioning correctly. I currently us Uppy to test, but its often hard to say why some error occurs without proper tests.

Unfortunately there is no shared test suite among servers. But I recommend looking at tus-node-server, tusd, and tusdotnet for inspiration. Those are the most tested servers.

Unfortunate indeed! I’m not sure how much I benefit reading other implementations has over reading the protocol itself, but Ill keep it in mind.

While opening a PR to the protocol repo I noticed an OpenAPI definition which may be helpful, although when using this in Postman I’m not exactly sure how I would pass chunks of a file.

In practice, we currently test with Uppy, which I understand runs tus-js-client under the hood. I think the low hanging fruit is to improve error handling for this library so that it could facilitate end-to-end server testing. Maybe I could get around to opening a PR to this end at some point this summer.

Thanks for the feedback. I recently started more serious work on a tool for testing implementations against protocol compliance. My current focus is on testing servers, but I hope to cover client implementations in the long run as well. It’s still to early to release it, but hopefully it can be released in the near future.

1 Like

Great to hear @marius, looking forward to try it out!