schangxiang@126.com
2024-06-16 0f89dfa00bb223dc0db4960bda4c8fe5d0b762a8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
using iWare_SCADA_BusinessLogical.Utils;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.Collections.Generic;
using System.IO;
 
namespace iWare_SCADA_Test
{
    [TestClass]
    public class UnitTest1
    {
        [TestMethod]
        public void TestMethod1()
        {
 
            //计算大头孔直径,大头孔直径=(大头上面X方向直径+大头上面Y方向直径+大头下面X方向直径+大头下面Y方向直径)/4
            List<decimal> valueList = new List<decimal>() {
                                                        SystemHelper.GetDecimal(""),
                                                        SystemHelper.GetDecimal("sss"),
                                                        SystemHelper.GetDecimal("12.365"),
                                                        SystemHelper.GetDecimal("201.24557"),
                                                        SystemHelper.GetDecimal("100"),
                                                    };
            var bb = SystemHelper.CalcDecimalAvg(valueList, 3);
            Assert.Fail();
        }
 
        [TestMethod]
        public void xx()
        {
            string path = ConfigHelper.GetConfigString("OP80QualityData_Test");//OP80的地址
 
            var newFiles = FileHelper.DetectNewFilesCSV(path, 300, DateTime.Now.AddDays(-10), DateTime.Now.AddDays(1));
 
            foreach (System.IO.FileInfo file in newFiles)
            {
                File.Move(file.FullName, "../CA4GC20TD_COPY/" + file.Name);//移动
            }
        }
    }
}