package com.tuoheng.admin.tzhl;

import com.tuoheng.admin.entity.Inspection;
import com.tuoheng.admin.tzhl.response.TZHLAirportFlightDataResponse;
import com.tuoheng.admin.tzhl.service.fly.data.FlyDataService;
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.SpringRunner;

import java.util.ArrayList;
import java.util.List;

/**
 * @Author ChengWang
 * @Date 2023/8/16
 */
@Slf4j
@RunWith(SpringRunner.class)
@SpringBootTest
public class TZHLGetFlightDataServiceTest {

    @Autowired
    private FlyDataService flyDataService;

    @Test
    public void test(){

        List<TZHLAirportFlightDataResponse> list = new ArrayList<>();

        TZHLAirportFlightDataResponse response = new TZHLAirportFlightDataResponse();
        response.setAbsp("0");
        response.setAct(1l);
        response.setAir("qww");
        response.setAlt("rerer");
        response.setAbsp("rrrr");
        response.setAltitudeFused("gggg");
        response.setAppConnected("kkkk");
        response.setArm("llll");
        response.setAttachRD(4l);
        response.setBat("eee");
        response.setBattery1CapacityPercent("nnnn");
        response.setBattery1HeatState("iiii");
        response.setBattery1Temperature("45");
        response.setBattery1Voltage("4.5");
        response.setBattery2CapacityPercent("333");
        response.setBattery2HeatState("2333");
        response.setBattery2Temperature("334");
        response.setBattery2Voltage("3.4");
        response.setControlDevice("ffff");
        response.setDeptId(23l);
        response.setAttachRD(5l);
        response.setDuration("kkkklll");
        response.setFlightMode("hahah");
        response.setAppConnected("sssss");
        response.setFocalLength("3434");
        response.setFuel("eee");
        response.setGimbalPitch("ooooo");
        response.setGimbalRoll("mmmm");
        response.setGimbalYaw("ccccc");
        response.setGps("223.44");
        response.setGroundConnected("fffff");
        response.setHead("eggffe");
        response.setHomeLocation("江苏生");
        response.setHt("dddd");
        //response.setId(3l);
        response.setInspectionId("23ddfgggg");
        response.setLat("rrrr");
        response.setLatLonAltitude("eet");
        response.setLng("2222");
        response.setMode(5l);
        response.setModuleSignal("qqqqq");
        response.setPit("weffg");
        response.setRcControlPosition("eeeeee");
        response.setRecordId(34l);
        response.setRemainingFlightTime("223344");
        response.setRoll("ergghy");
        response.setSatellite("rnrnrne");
        response.setSpd("rrrredddd");
        response.setTc("lllleeee");
        response.setTemp("eeedwws");
        response.setTenantId("wewewew");
        response.setTime(3344l);
        response.setUavId(3l);
        response.setUavNo("rewwqs");
        response.setUltrasonicHeight("enrhhhh");
        response.setVelocityZ("gghhffdr");
        response.setVideoStreamSource("2gg33345");
        response.setVol("eefght");
        response.setZoomRatio("sddrhgt");

        //list.add(null);

        Inspection inspection = new Inspection();
        inspection.setTenantId("112");
        inspection.setId("12334");
        //flyDataService.getFlyData(inspection,list);
        log.info("数据入库成功");

        System.out.println("数据入库成功");




    }


}
