public void BeginOpenAssemblies(string[] filenames, bool partialTrust) { var newRoots = new List<RowModel>(); for (int i = 0; i < filenames.Length; i++) { string fn = filenames[i]; string baseFolder = Path.GetFullPath(Path.Combine(fn, "..")); var task = AppDomainStarter.Start<AssemblyScanTask>(baseFolder, Path.GetFileName(fn), new object[] { fn, baseFolder }, partialTrust); var root = new TaskRowModel(Path.GetFileName(fn), TestNodeType.Assembly, task, false); newRoots.Add(root); _roots.Add(root); } _runner.AddTasks(newRoots.Select(row => row.Task)); _runner.AutoStartTasks(); }
public void BeginOpenAssemblies(string[] filenames, bool partialTrust) { var newRoots = new List <RowModel>(); for (int i = 0; i < filenames.Length; i++) { string fn = filenames[i]; string baseFolder = Path.GetFullPath(Path.Combine(fn, "..")); var task = AppDomainStarter.Start <AssemblyScanTask>(baseFolder, Path.GetFileName(fn), new object[] { fn, baseFolder }, partialTrust); var root = new TaskRowModel(Path.GetFileName(fn), TestNodeType.Assembly, task, false); newRoots.Add(root); _roots.Add(root); } _runner.AddTasks(newRoots.Select(row => row.Task)); _runner.AutoStartTasks(); }