Skip to content

generalizing riak_test [JIRA: RIAK-2092] #260

Open
@Licenser

Description

@Licenser

Hi,
I have played a bit with riak_test and noticed it's very tightly tied to riak_kv, which I personally think is a bit of a shame. The framework itself is awesome and I think could be used far beyond the realm of riak_kv, it's qutie easy to adapt for riak_core based applications but I think it would be posible to generalize/moduralize it to a point where it would be useful for testing any kind of distributed erlang application.

That said it's not a blind 'please do this for me NOW!' feature request I'm planning to invest effort into this given there is a general interest into this and a decent chance to get a setup like this merged.

What I was thinking about is making riak_test somewhat of a library with 'extending' libraries that specialise on certain aspects.

A rough idea would be something like this:

  • riak_test
    • provides the base infrastructure of running tests, logging validating
    • provides methods to run shell commands, remote commands on nodes, spawn nodes etc.
  • riak_core_test
    • requires riak_test
    • provides some general tests that should work on all riak_core applications
    • provide functions to manipulate riak_core applications (build the ring, join nodes, take them down etc)
  • riak_kv_test
    • requires riak_core_test
    • provides riak_kv tests
    • provides functions specific to riak_kv

It would then be nice to have something like a riak_test rebar plugin which sets up a basik testing framework in which a user then can just require riak_core_tests or riak_kv_tests and build additional settings based on that. It would allos allow later on to make some more libraires that could dynamically be included that abstract over other aspects of testing.

Cheers,
Heinz

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions