giraph-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sebastian Schelter (Updated) (JIRA)" <>
Subject [jira] [Updated] (GIRAPH-51) Provide unit testing tool for Giraph algorithms
Date Wed, 16 Nov 2011 10:22:51 GMT


Sebastian Schelter updated GIRAPH-51:

    Attachment: GIRAPH-51-2.patch

Hi Jakob,

I moved InternalVertexRunner to the src as you suggested.

I think we have to separate the unit tests into two categories:

The first one would be testing single methods, usually invoking compute() and verifying the
behavior of the vertex (I suppose that's what you aimed at with your last comment). To accomplish
that one need not really run the system, it should be sufficient to injected mocked dependencies.
 I added two tests for SimpleShortestPathVertex as an example for such tests. I created a
helper class for convenient mocking of dependencies like the hadoop configuration e.g. and
for configuring the vertex.

The second category, which InternalVertexRunner aims at would be something like a local "integration"
test on toy data. It runs the system in a single JVM and executes the whole lifecycle of an
algorithm (reading input from disk, running the supersteps, writing output etc). Although
these tests are no compensation for real integration testing, they are often very helpful
in finding subtle bugs, that normal unit testing cannot discover.

> Provide unit testing tool for Giraph algorithms
> -----------------------------------------------
>                 Key: GIRAPH-51
>                 URL:
>             Project: Giraph
>          Issue Type: Improvement
>            Reporter: Jakob Homan
>            Assignee: Sebastian Schelter
>         Attachments: GIRAPH-51-2.patch, GIRAPH-51.patch
> It would be nice to have a little tool, similar to MRUnit, that would allow Giraph application
writers to quickly unit test their algorithms.  The tool could take a Vertex implementation,
a set of input and expected output and verify that after the specified number of supersteps,
we've gotten what we expect.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message