'An L{IPerspective} implementation which does not subclass
L{Avatar} can expose remote methods for the client to call.'

def test_NSP(self):

    factory = pb.PBClientFactory()
    d = factory.login(credentials.UsernamePassword('user', 'pass'), 'BRAINS!')
    reactor.connectTCP('127.0.0.1', self.portno, factory)
    d.addCallback((lambda p: p.callRemote('ANYTHING', 'here', bar='baz')))
    d.addCallback(self.assertEqual, ('ANYTHING', ('here',), {'bar': 'baz'}))
    def cleanup(ignored):
        factory.disconnect()
        for p in self.factory.protocols:
            p.transport.loseConnection()
    d.addCallback(cleanup)
    return d
