[Libwebsockets] regarding testing my websockets server using autobahn test suite

Andy Green andy at warmcat.com
Tue Jun 21 08:37:17 CEST 2016



On 06/21/2016 01:30 PM, Suman.Patro-TRN wrote:
> Hello,
>
>            I would like to know whether is it possible to test my
> websocket server implemented using libwebsockets library using autobahn
> test suite.
>
> How could that be done? Please elaborate.

We test lws client mode against Autobahn and pass everything (including 
all the RFC7692 permessage-deflate tests) using the lws echo client 
except two tests about multiple PING inflight that is not required in 
the spec.

https://libwebsockets.org/reports/clients/index.html

Their docs are a bit difficult to understand as to what the server test 
wants...

http://autobahn.ws/testsuite/usage.html#usage

By fiddling about with it I could see it by default wants to test a 
server on 127.0.0.1:9001, I couldn't see from the --help either how to 
change that.  So I made my local lwsws listen on 9001, then it tried to 
do its tests.

$ wstest -m fuzzingclient

That can make it try to run tests, which don't go anywhere because there 
is no echo protocol running.  But when ^C-ing it, it does at least 
produce reports/servers/*, which is full of grey since no echo server. 
So I think if we give it an echo server, it should do something.

I don't think you can use it to "test my websocket server" per se, you 
can only use it to test an echo protocol that is presumably not what you 
have as your server protocol.  But in doing that, it does test other 
lower level things about the library.  It just doesn't really test "your 
server".

I'm not going to do anything more with the standalone servers, so I'll 
look at adding an echo protocol plugin in the next days and see what 
happens.

-Andy

>           Thanks and regards,
>
>           Suman
>
> *Larsen & Toubro Limited *
>
> *www.larsentoubro.com*
>
> This Email may contain confidential or privileged information for the
> intended recipient (s). If you are not the intended recipient, please do
> not use or disseminate the information, notify the sender and delete it
> from your system.
>
>
>
> _______________________________________________
> Libwebsockets mailing list
> Libwebsockets at ml.libwebsockets.org
> http://libwebsockets.org/mailman/listinfo/libwebsockets
>



More information about the Libwebsockets mailing list