couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Julian Doherty <julian.doherty...@gmail.com>
Subject Re: Testing map/reduce functions
Date Fri, 10 Sep 2010 10:58:01 GMT
I've used Rhino (Java based Javascript interpreter) to test map/reduce
functions before. You need to expose an "emit" function and probably make
assertions on what gets passed to it.

Apart from that the map/reduce functions as called by Couch are pretty
idempotent, so are easy to test in isolation.

On 9 September 2010 23:08, Johannes Schneider <mailings@cedarsoft.com>wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi guys,
>
> I would like to test my map and reduce functions without CouchDB. I'd
> like to write some unit tests that verify that those functions work as
> expected...
>
> Does anybody out there have any hints how this can be done? If it is
> Java based and portable this would be great...
>
>
> Thanks,
>
> Johannes
> - --
> Johannes Schneider - blog.cedarsoft.com
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.10 (GNU/Linux)
>
> iQEcBAEBAgAGBQJMiNxWAAoJEAytD9R7Qv6dtPQH/A6OetCJm7KOjHIFVgBBWPcD
> aFR8xHqKIjALjZg5jPwm5ALw+2tDaPhKIjU0JAv3tfHiuqHdpUUe9z+y0Oz3j5ey
> Mn6B7qr2KhIN3VGJGC5GOGkQoHmeMaJ2rus2ETr8TmwxXk+bXV0I0nn9K6D+CKP9
> c6G5YXGnA5mc6vScRERGyburb6ltp0C6glK2me/F/BmCDs8oEoBpiYh6KGP/lxK2
> P+B1TqvAPHCYL2vqulUN4/gD3ceme6vlqqaL74JpD+3z4yuj82ljg94Gk6AfzVVU
> cEyexX2/oet7f9OLiuZiOWyYGSq+a/R87uKA42Hr2w9HR0fEfOo4Qxjr9gQY+iw=
> =pJe2
> -----END PGP SIGNATURE-----
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message