unit tests and construction of referencer composite function.