package com.yihu.hos.services;

import com.yihu.hos.HosAdminApplication;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.SpringApplicationConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;

/**
 * @created Airhead 2016/8/4.
 */
@RunWith(SpringJUnit4ClassRunner.class)
@SpringApplicationConfiguration(classes = HosAdminApplication.class)
public class ServiceFlowEventServiceTest {
    @Autowired
    ServiceFlowEventService serviceFlowEventService;

    @Test
    public void processorAdded() throws Exception {
        serviceFlowEventService.processorAdded("hosServiceEventService", "services", "HosServiceEventService", "com/yihu/hos/services/HosServiceEventService.class");
    }

    @Test
    public void processorDataChanged() throws Exception {
        serviceFlowEventService.processorDataChanged("hosServiceEventService", "services", "HosServiceEventService", "com/yihu/hos/services/HosServiceEventService.class");
    }

    @Test
    public void routeDefineAdded() throws Exception {
        serviceFlowEventService.routeDefineAdded("hosServiceEventService", "services", "HosServiceEventService", "com/yihu/hos/services/HosServiceEventService.class");
    }

    @Test
    public void routeDefineChanged() throws Exception {
        serviceFlowEventService.routeDefineChanged("hosServiceEventService", "services", "HosServiceEventService", "com/yihu/hos/services/HosServiceEventService.class");
    }

    @Test
    public void routeDefineDelete() throws Exception {
        serviceFlowEventService.routeDefineDelete("hosServiceEventService", "services", "HosServiceEventService");
    }
}