/// <summary>
 /// This service just uploads the file, it creates no DB objects
 /// </summary>
 public async Task UploadAsync(UploadedFileRequest uploadedFile)
 {
     try
     {
         MsgLogger.WriteTrace("FileUploadService Uploading file");
         await ApiClient.PostAsJsonAsync <UploadedFileRequest>("/api/fileupload", uploadedFile);
     }
     catch (Exception e)
     {
         MsgLogger.WriteError($"FileUploadServie exception: {e.Message}");
         throw;
     }
     finally
     {
         MsgLogger.WriteTrace("FileUploadService done Uploading file");
     }
 }
        public void Display(string prefix, string output, string error, int exitCode)
        {
            //xml message is proceeded with some other console info
            var startIndex = output.IndexOf("<?xml");

            if (startIndex < 0)
            {
                _logger.WriteError("TEST", "nunit returned no xml output. Output was: " + output + " Error was: " + error);
                return;
            }
            output = output.Substring(startIndex);
            var xmlDoc = XDocument.Parse(output);

            foreach (XElement testSuite in xmlDoc.Root.Elements("test-suite"))
            {
                ProcessTestSuite(testSuite);
            }

            _logger.Write("TEST", String.Format("Run completed. Successfull: {0}  Failed: {1}  Ignored: {2}", successfull, failed, ignored));
        }
예제 #3
0
 public static void WriteError(string message)
 {
     InternalLogger.WriteError("ERROR", message);
 }
예제 #4
0
 public void WriteError(string type, string message)
 {
     InternalLogger.WriteError(type, message);
 }