Simplify, maaaan, simplifyyyyyy...
Generated metadata elements

+ Create metadata elements in setup and remove in teardown
+ Use dynamic element codes
Change name of collections and add test
More flexible match type and operator specification

+ Allow "case insensitive" as well as "caseInsensitive"
Many more unit tests

+ Add unit tests for various circumstances - adding and removing
  relationships in various combinations
Remove unused config
Generate relationship type

+ Remove all dependencies on configurable data
Remove TODO

+ The test was previously leaving remnant data in the
  ca_metadata_type_restrictions table, but it doesn't seem to
  be doing that any more, so removing the TODO note about it
Documentation and method rename.