Re: [mongrel2] Test Coverage Nearly 80%
- From:
- Alex Gartrell
- Date:
- 2010-08-20 @ 13:54
So as long as we're talking about testing, I think it's worth talking about
what we should add to kegogi.
Right now, I'm planning on adding a content= param to verify the content
with either a string or pattern. Also planning on adding command line
switches to run n threads and/or repeat the tests m times. The goal being
that you can throw a million requests at it.
I'll probably get to doing this tonight or within the next couple days, so
please share if there are any features you'd like.
Alex
On Fri, Aug 20, 2010 at 3:56 AM, Zed A. Shaw <zedshaw@zedshaw.com> wrote:
> Hey Everyone,
>
> We've managed to get the test coverage up to around 80%:
>
> http://mongrel2.org/static/coverage/src.html
>
> The majority of that is from unit tests that are automated. Then
> there's some simple system tests I did real quick. I tried using kegogi
> but, ehem, it actually causes some weird crashes in Mongrel2, so awesome
> it's doing its job.
>
> Kegogi is awesome BTW Alex, nice job. I'm going to be getting into that
> code more and then will be using it in the system tests. If you folks
> want to try it out, check out examples/kegogi to see what it does. It's
> basically a scriptable web server tester that we'll be using to pound
> more edge cases on mongrel2 and hit some fuzzing stuff.
>
> This coverage report is a little hard to make, but for most folks just
> do:
>
> make coverage
>
> And you should get the plain unit test version, which has lower
> coverage. If you want to do the full on test do this:
>
>
> make coverage
>
> run mongrel2, examples/chat/chat.py, examples/chat/www.py,
> examples/http_0mq/http.py basically everything and in separate windows.
>
> make system_tests
> make coverage_report
>
> That'll basically test as much as we can without using a browser.
>
> I think that's enough coverage now to then get in and start fixing bugs
> and cleaning up features. Just doing this has already found a few spots
> that needed cleaning up in the APIs, and it should make it much easier
> to extend in the near future.
>
> --
> Zed A. Shaw
> http://zedshaw.com/
>
Re: [mongrel2] Test Coverage Nearly 80%
- From:
- Zed A. Shaw
- Date:
- 2010-08-20 @ 17:48
On Fri, Aug 20, 2010 at 09:54:52AM -0400, Alex Gartrell wrote:
> So as long as we're talking about testing, I think it's worth talking about
> what we should add to kegogi.
>
> Right now, I'm planning on adding a content= param to verify the content
> with either a string or pattern. Also planning on adding command line
> switches to run n threads and/or repeat the tests m times. The goal being
> that you can throw a million requests at it.
Ah yeah that'd be nice. I'll put some tickets in for kegogi
specifically. Mostly I think just cleaned up output, these two you got
here, and I noticed it doesn't shutdown the connection right but let me
research that.
Oh, and I did something cool. So, you know how the tests are
tests/blah_tests? Well if you make a kegogi script there, name it as a
test, then put the shell script line:
#!./examples/kegogi/build/kegogi
Make it executable, and then the test runner will just run it. No need
for anything other than kegogi. I really like that so it'd be great to
go that direction where kegogi is just like a script.
--
Zed A. Shaw
http://zedshaw.com/