open-eio / opk-phant-cli

Pipe database driver that sends data to a Phant service like http://data.sparkfun.com
0 stars 2 forks source link

test suite #3

Open jywarren opened 9 years ago

jywarren commented 9 years ago

Esp. in PRs like this one: https://github.com/openpipekit/opk-phant-cli/pull/2 it can be tough to test these out; have you considered adopting a test suite -- it could run a local Phant-like service and provide a variety of piped inputs, streamed and non-streamed, JSON and plain text?

rjcorwin commented 9 years ago

Tests would be great. I've been meaning to look into how to creat a Phant stream via their API, I'm not sure it can be done. If that's the case, then we could write a test around a single stream that is dedicated for the tests.

jywarren commented 9 years ago

You can - there's a phant node package here: https://github.com/dpjanes/iotdb-phant-client

Yeah i was thinking about this too - would the test suite rely on the Sparkfun phant service, then? or maybe we could create a stream specifically for testing, that everyone could use? Also I was thinking of writing a fake serial sensor source or something... like a virtual /dev/ttyUSB0 or something.

On Wed, Jun 17, 2015 at 7:37 AM, R.J. Steinert notifications@github.com wrote:

Tests would be great. I've been meaning to look into how to creat a Phant stream via their API, I'm not sure it can be done. If that's the case, then we could write a test around a single stream that is dedicated for the tests.

— Reply to this email directly or view it on GitHub https://github.com/open-eio/opk-phant-cli/issues/3#issuecomment-112826515 .