def METHOD_NAME(self):
    self.num_reconfig += 1
    from buildbot.config import BuilderConfig
    from buildbot.process.factory import BuildFactory
    from buildbot.steps.shell import ShellCommand
    from buildbot.util.service import BuildbotService
    class MyShellCommand(ShellCommand):
        def getResultSummary(self):
            service = self.master.service_manager.namedServices['myService']
            return {"step": f'num reconfig: {service.num_reconfig}'}
    class MyService(BuildbotService):
        name = "myService"
        def reconfigService(self, num_reconfig):
            self.num_reconfig = num_reconfig
            return defer.succeed(None)
    config_dict = {
        'builders': [
            BuilderConfig(name="builder", workernames=["worker1"],
                          factory=BuildFactory([MyShellCommand(command='echo hei')])),
        ],
        'workers': [self.createLocalWorker('worker1')],
        'protocols': {'null': {}},
        # Disable checks about missing scheduler.
        'multiMaster': True,
        'db_url': 'sqlite://',  # we need to make sure reconfiguration uses the same URL
        'services': [MyService(num_reconfig=self.num_reconfig)]
    }
    if self.num_reconfig == 3:
        config_dict['services'].append(MyService(name="myService2",
                                                 num_reconfig=self.num_reconfig))
    return config_dict