Пример #1
0
 public void TearDown()
 {
     if (Directory.Exists(BuildArtifacts.BaseDirectory))
     {
         Directory.Delete(BuildArtifacts.BaseDirectory, true);
     }
     BuildArtifacts.Clear();
 }
Пример #2
0
        public void TearDown()
        {
            if (!Directory.Exists(BuildArtifacts.BaseDirectory))
            {
                return;
            }

            var currentArtifactFiles = Directory.GetFiles(BuildArtifacts.BaseDirectory, "*.json", SearchOption.TopDirectoryOnly);

            foreach (var file in currentArtifactFiles.Except(m_LastArtifactFiles ?? Enumerable.Empty <string>()))
            {
                File.Delete(file);
            }

            BuildArtifacts.Clear();
        }