package com.liquidnet.service.chime.test;

import com.liquidnet.common.third.shumei.util.ShumeiUtil;
import lombok.extern.slf4j.Slf4j;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;

/**
 * @author AnJiabin <anjiabin@zhengzai.tv>
 * @version V1.0
 * @Description: TODO
 * @class: TestShumei
 * @Package com.liquidnet.service.chime.test
 * @Copyright: LightNet @ Copyright (c) 2021
 * @date 2021/9/8 13:43
 */
@Slf4j
@RunWith(SpringJUnit4ClassRunner.class)
@SpringBootTest
public class TestShumei {
    @Autowired
    private ShumeiUtil shumeiUtil;

    @Test
    public void checkText(){
        shumeiUtil.checkText("user123","习近平");
    }
    @Test
    public void checkImage(){
        //暴力血腥
//        String imageUrl = "https://image11.m1905.cn/uploadfile/s2010/0603/20100603015651967.jpg";
        //涉黄
        String imageUrl = "https://img2.baidu.com/it/u=276463273,2526848266&fm=26&fmt=auto&gp=0.jpg";
        shumeiUtil.checkImage("user123",imageUrl);
    }
}
