zostay / RakuWAPI

The Web API for Raku (RakuWAPI)
Artistic License 2.0
24 stars 5 forks source link

Add roast-style tests for P6SGI implementations #7

Open zostay opened 9 years ago

zostay commented 9 years ago

It would be nifty to have a roaster like the Perl 6 roast specification that could verify that all the MUST statements are implemented by a server and provide a list of todo tests for all the SHOULDs and extensions. I imagine such a thing would need to be in two parts:

  1. The initializer, which is a tool that the implementation calls to pass in hooks for server setup and helpers to make requests and capturing responses from the server. It has to be flexible to handle all the different kinds of implementation that might occur: HTTP, CGI, FastCGI, SCGI, etc. This part would also validate the responses.
  2. One or more apps that test the server from within, verifying that all the environment variables are passed in correct and providing content that can be verified by the first part.

There also needs to be an easy way to pull these tests into a server so it can be verified against the latest requirements easily without a bunch of toolchain and effort by server maintainers.