Register multiple fields at once, added tests.