Fixing router registration and adding test