def setUp(self):
     self.mc = self.add_server(MockMemcached())
     self.mcrouter_mc = self.add_mcrouter(self.config_mc,
                                          extra_args=self.extra_args,
                                          bg_mcrouter=True)
     self.mcrouter = self.add_mcrouter(self.config,
                                       extra_args=self.extra_args)
    def setUp(self):
        mc_ports = [
            11510, 11511, 11512, 11513,
            11520, 11521, 11522, 11523,
            11530, 11531, 11532, 11533,
            11541]
        mc_gut_port = 11540
        tmo_port = 11555

        # have to do these before starting mcrouter
        self.mcs = [self.add_server(MockMemcached(), logical_port=port)
                    for port in mc_ports]
        self.mc_gut = self.add_server(MockMemcached(), logical_port=mc_gut_port)
        self.mcs.append(self.mc_gut)

        self.add_server(SleepServer(), logical_port=tmo_port)

        for port in [65532, 65522]:
            self.add_server(DeadServer(), logical_port=port)

        self.mcrouter = self.add_mcrouter(self.config)
 def make_memcached(self):
     return MockMemcached()
Exemple #4
0
 def setUp(self):
     self.add_server(MockMemcached(), logical_port=12345)
     self.mcrouter = self.add_mcrouter(self.config, None, self.extra_args)
Exemple #5
0
 def make_memcached(self):
     return MockMemcached() if self.use_mock_mc else Memcached()
 def setUp(self):
     # The order here corresponds to the order of hosts in the .json
     self.mc1 = self.add_server(MockMemcached())
     self.mc2 = self.add_server(MockMemcached())