juju/charmstore — pull request #45 by rogpeppe (2014-07-30 12:06:43+00:00)
Title: internal/v4: refactor tests

We create a table with an entry for each kind of metadata so
that it's easy to add new entries and new tests that
test the metadata in arbitrary configurations without
writing reams of duplicated test code.

We also fix router so that it works correctly with
typed nil data, which avoids an if statement in
every metadata handler.