Would just `assert.throw(getter.buildUrl, ...)` work here?