Пример #1
0
        public void ChannelDataChunkAdapter_AddToStore_Max_Document_Size_Exceeded_Successfully()
        {
            // Adjust Points and Nodes for large file
            WitsmlSettings.LogMaxDataPointsAdd = 5000000;
            WitsmlSettings.LogMaxDataNodesAdd  = 15000;

            // Load Well from file and assert success response
            var response = DevKit.Add_Well_from_file(
                BuildDataFileName(string.Format(_exceedFileFormat, "well")));

            // There is no response if the Well already exists in the database
            if (response != null)
            {
                Assert.AreEqual((short)ErrorCodes.Success, response.Result);
            }

            // Load Wellbore from file and assert success response
            response = DevKit.Add_Wellbore_from_file(
                BuildDataFileName(string.Format(_exceedFileFormat, "wellbore")));
            // There is no response if the Wellbore already exists in the database
            if (response != null)
            {
                Assert.AreEqual((short)ErrorCodes.Success, response.Result);
            }

            // Load Log from file that is larger than 16MB and assert success response
            response = DevKit.Add_Log_from_file(
                BuildDataFileName(string.Format(_exceedFileFormat, "log")));
            // Log should always succeed
            if (response != null)
            {
                Assert.AreEqual((short)ErrorCodes.Success, response.Result);
            }
        }
Пример #2
0
        private void AddLogs()
        {
            var logFiles = Directory.GetFiles(_dataDir, "*_Log.xml");

            foreach (var xmlfile in logFiles)
            {
                var response = _devKit.Add_Log_from_file(xmlfile);
                if (response != null)
                {
                    Assert.AreEqual((short)ErrorCodes.Success, response.Result);
                }
            }
        }