Fixed a bug where the default 'from' value wasn't actually set if it wasn't specified, and refactored the tests.