539 references to FileInfo
aspire (4)
Program.cs (1)
48var settingsFile = new FileInfo(settingsFilePath);
Projects\ProjectLocator.cs (3)
77var settingsFile = new FileInfo(Path.Combine(searchDirectory.FullName, ".aspire", "settings.json")); 88var appHostFile = new FileInfo(qualifiedAppHostPath); 189var settingsFile = new FileInfo(settingsFilePath);
Aspire.Cli.Tests (17)
DotNet\DotNetCliRunnerTests.cs (1)
18var projectFile = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, "AppHost.csproj"));
Projects\ProjectLocatorTests.cs (15)
24var projectFile = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, "AppHost.csproj")); 45var targetAppHostProjectFile = new FileInfo(Path.Combine(targetAppHostDirectory.FullName, "TargetAppHost.csproj")); 49var otherAppHostProjectFile = new FileInfo(Path.Combine(otherAppHostDirectory.FullName, "OtherAppHost.csproj")); 53var aspireSettingsFile = new FileInfo(Path.Combine(workspaceSettingsDirectory.FullName, "settings.json")); 82var targetAppHostProjectFile = new FileInfo(Path.Combine(targetAppHostDirectory.FullName, "TargetAppHost.csproj")); 86var otherAppHostProjectFile = new FileInfo(Path.Combine(otherAppHostDirectory.FullName, "OtherAppHost.csproj")); 90var aspireSettingsFile = new FileInfo(Path.Combine(workspaceSettingsDirectory.FullName, "settings.json")); 114var projectFile1 = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, "AppHost1.csproj")); 117var projectFile2 = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, "AppHost2.csproj")); 135var appHostProject = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, "AppHost.csproj")); 138var webProject = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, "WebProject.csproj")); 183var projectFile = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, "AppHost.csproj")); 200var projectFile = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, "AppHost.csproj")); 220var appHostProjectFile = new FileInfo(Path.Combine(appHostDirectory.FullName, "AppHost.csproj")); 234var settingsFile = new FileInfo(Path.Combine(workspace.WorkspaceRoot.FullName, ".aspire", "settings.json"));
TestServices\TestProjectLocator.cs (1)
26return new FileInfo(fakeProjectFilePath);
Aspire.EndToEnd.Tests (1)
tests\Shared\TemplatesTesting\TemplateCustomHive.cs (1)
55installTemplates = packageIdAndPaths.Where(t => new FileInfo(t.path).LastWriteTimeUtc > dirWriteTime).Any();
Aspire.Hosting (3)
Dcp\KubernetesService.cs (2)
545var fileInfo = new FileInfo(locations.DcpKubeconfigPath); 549fileInfo = new FileInfo(locations.DcpKubeconfigPath);
src\Shared\LaunchProfiles\LaunchProfileExtensions.cs (1)
80var projectFileInfo = new FileInfo(projectMetadata.ProjectPath);
Aspire.Hosting.Azure.Functions (1)
src\Shared\LaunchProfiles\LaunchProfileExtensions.cs (1)
80var projectFileInfo = new FileInfo(projectMetadata.ProjectPath);
Aspire.Templates.Tests (1)
tests\Shared\TemplatesTesting\TemplateCustomHive.cs (1)
55installTemplates = packageIdAndPaths.Where(t => new FileInfo(t.path).LastWriteTimeUtc > dirWriteTime).Any();
BuildValidator (1)
Program.cs (1)
315var originalBinary = new FileInfo(assemblyInfo.FilePath);
dotnet-openapi (1)
Commands\BaseCommand.cs (1)
122return new FileInfo(project);
dotnet-svcutil.xmlserializer (2)
Microsoft\Tools\ServiceModel\SvcUtil\Options.cs (2)
220FileInfo fileInfo = new FileInfo(value); 425var file = new FileInfo(path);
dotnet-svcutil-lib (9)
CommandProcessorOptions.cs (1)
457this.OutputFile = new FileInfo(outputFile);
Shared\MSBuildProj.cs (3)
316fullPath = new FileInfo(Path.Combine(msbuildProj.DirectoryPath, binReference)).FullName; 797var assetsFile = new FileInfo(Path.Combine(this.DirectoryPath, "obj", "project.assets.json")).FullName; 1007.Select(f => new FileInfo(f))
Shared\Options\ApplicationOptions.cs (1)
163return Deserialize<TOptionsBase, OptionsSerializer<TOptionsBase>>(null, new FileInfo(filePath), throwOnError);
Shared\Options\OptionValueParser.cs (1)
60value = CreateValue<FileInfo>(() => new FileInfo(stringValue), option, stringValue);
Shared\Options\UpdateOptions.cs (2)
91this.OutputFile = new FileInfo(relPath); 109this.OutputFile = new FileInfo(Path.Combine(optionsFileDirectory.FullName, this.OutputFile.OriginalPath()));
Shared\ProjectPropertyResolver.cs (1)
207.Select(f => new FileInfo(f));
IIS.ShadowCopy.Tests (1)
ShadowCopyTests.cs (1)
378var fileInfo = new FileInfo(filePath)
illink (1)
Microsoft.AspNetCore.DataProtection.Extensions.Tests (1)
DataProtectionProviderTests.cs (1)
74var file = new FileInfo(newFileName);
Microsoft.AspNetCore.FunctionalTests (1)
WebHostFunctionalTests.cs (1)
240var solutionFileInfo = new FileInfo(Path.Combine(directoryInfo.FullName, "DefaultBuilder.slnf"));
Microsoft.AspNetCore.Http (1)
SendFileFallback.cs (1)
25var fileInfo = new FileInfo(filePath);
Microsoft.AspNetCore.Http.Results (1)
PhysicalFileHttpResult.cs (1)
166var fileInfo = new FileInfo(path);
Microsoft.AspNetCore.HttpLogging (2)
FileLoggerProcessor.cs (2)
189var fileInfo = new FileInfo(fullName); 216fileInfo = new FileInfo(fullName);
Microsoft.AspNetCore.InternalTesting (2)
TestPathUtilities.cs (2)
19var projectFileInfo = new FileInfo(Path.Combine(directoryInfo.FullName, $"{solution}.slnf")); 25projectFileInfo = new FileInfo(Path.Combine(directoryInfo.FullName, "AspNetCore.slnx"));
Microsoft.AspNetCore.Mvc.Core (1)
Infrastructure\PhysicalFileResultExecutor.cs (1)
125var fileInfo = new FileInfo(path);
Microsoft.AspNetCore.Mvc.Testing (1)
WebApplicationFactory.cs (1)
511var depsFile = new FileInfo(Path.Combine(AppContext.BaseDirectory, depsFileName));
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (1)
ResponseSendFileTests.cs (1)
32FileLength = new FileInfo(AbsoluteFilePath).Length;
Microsoft.Build (6)
BackEnd\Components\Scheduler\Scheduler.cs (2)
1072System.IO.FileInfo f = new FileInfo(_configCache[unscheduledRequest.BuildRequest.ConfigurationId].ProjectFullPath); 1114System.IO.FileInfo f = new FileInfo(_configCache[unscheduledRequest.BuildRequest.ConfigurationId].ProjectFullPath);
BuildEnvironmentHelper.cs (1)
559currentMSBuildExeFile = new FileInfo(currentMSBuildExePath);
Construction\ProjectRootElement.cs (1)
1981FileInfo fileInfo = new FileInfo(path);
FileUtilities.cs (2)
196FileInfo file = new(testFilePath); 999fileInfo = new FileInfo(filePath);
Microsoft.Build.CommandLine.UnitTests (1)
PerfLog_Tests.cs (1)
54files.ShouldAllBe(f => new FileInfo(f).Length > 0);
Microsoft.Build.Engine.OM.UnitTests (6)
BuildEnvironmentHelper.cs (1)
559currentMSBuildExeFile = new FileInfo(currentMSBuildExePath);
Definition\ProjectItem_Tests.cs (1)
324FileInfo info = new FileInfo(path);
FileUtilities.cs (2)
196FileInfo file = new(testFilePath); 999fileInfo = new FileInfo(filePath);
ObjectModelRemoting\LinkedEvaluationModify_Tests.cs (2)
51var lwtBefore = new FileInfo(proj1Path).LastWriteTimeUtc; 70var lwtAfter = new FileInfo(proj1Path).LastWriteTimeUtc;
Microsoft.Build.Engine.UnitTests (9)
BackEnd\TargetBuilder_Tests.cs (6)
219var fileA = new FileInfo(files.CreatedFiles[0]); 220var fileB = new FileInfo(files.CreatedFiles[1]); 221var fileC = new FileInfo(files.CreatedFiles[2]); 263var fileA = new FileInfo(files.CreatedFiles[0]); 264var fileB = new FileInfo(files.CreatedFiles[1]); 265var fileC = new FileInfo(files.CreatedFiles[2]);
FileLogger_Tests.cs (2)
379var result = new FileInfo(logFile); 381Assert.Equal(0, new FileInfo(logFile).Length);
FileUtilities_Tests.cs (1)
195Assert.Equal(info.LastWriteTime, new FileInfo(file).LastWriteTime);
Microsoft.Build.Tasks.CodeAnalysis (2)
src\Compilers\Core\MSBuildTask\Vbc.cs (2)
305FileInfo actualPdbInfo = new FileInfo(actualPdb); 313FileInfo desiredPdbInfo = new FileInfo(desiredLocation);
Microsoft.Build.Tasks.CodeAnalysis.Sdk (2)
src\Compilers\Core\MSBuildTask\Vbc.cs (2)
305FileInfo actualPdbInfo = new FileInfo(actualPdb); 313FileInfo desiredPdbInfo = new FileInfo(desiredLocation);
Microsoft.Build.Tasks.Core (18)
BootstrapperUtil\BootstrapperBuilder.cs (3)
225var fi = new FileInfo(de.Value); 1514var fi = new FileInfo(packageFileSource.Value); 1620var fi = new FileInfo(filePath);
BuildEnvironmentHelper.cs (1)
559currentMSBuildExeFile = new FileInfo(currentMSBuildExePath);
DownloadFile.cs (1)
180var destinationFile = new FileInfo(Path.Combine(destinationDirectory.FullName, filename));
FileState.cs (3)
126Length = new FileInfo(_filename).Length; 143var fileInfo = new FileInfo(_filename); 194var length = (new FileInfo(_filename)).Length;
FileUtilities.cs (2)
196FileInfo file = new(testFilePath); 999fileInfo = new FileInfo(filePath);
ManifestUtil\SecurityUtil.cs (1)
190filesInfo[i] = new FileInfo(files[i]);
ManifestUtil\Util.cs (1)
221FileInfo fi = new FileInfo(path);
Move.cs (1)
191var info = new FileInfo(file);
ResGenDependencies.cs (1)
373var outputFile = new FileInfo(FileUtilities.FixFilePath(outputFileName));
SdkToolsPathUtility.cs (1)
150return new FileInfo(filePath).Exists;
TlbReference.cs (1)
306var wrapperFile = new FileInfo(wrapperPath);
Unzip.cs (1)
176FileInfo destinationPath = new(fullDestinationPath);
ZipDirectory.cs (1)
49FileInfo destinationFile = new FileInfo(DestinationFile.ItemSpec);
Microsoft.Build.Tasks.UnitTests (49)
ConvertToAbsolutePath_Tests.cs (3)
26FileInfo testFile = new FileInfo(fileName); 58FileInfo testFile = new FileInfo(fileName); 88FileInfo testFile = new FileInfo(fileName);
Copy_Tests.cs (2)
592FileInfo sourcefi = new FileInfo(source); 595FileInfo destinationfi = new FileInfo(destination);
DownloadFile_Tests.cs (3)
77FileInfo file = new FileInfo(Path.Combine(folder.Path, "foo.txt")); 122FileInfo file = new FileInfo(Path.Combine(folder.Path, filename)); 156FileInfo file = new FileInfo(Path.Combine(folder.Path, filename));
FileStateTests.cs (22)
50delegate () { var x = new FileInfo(new String('x', 5000)).LastWriteTime; }, 62FileInfo info = new FileInfo(file); 81FileInfo info = new FileInfo(file); 108FileInfo info = new FileInfo(file); 127FileInfo info = new FileInfo(file); 146FileInfo info = new FileInfo(file); 165FileInfo info = new FileInfo(file); 184FileInfo info = new FileInfo(file); 210FileInfo info = new FileInfo(file); 236FileInfo info = new FileInfo(file); 262FileInfo info = new FileInfo(file); 290FileInfo info = new FileInfo(file); 315FileInfo info = new FileInfo(file); 325(new FileInfo(file)).IsReadOnly = false; 333Assert.Equal(new FileInfo(Path.GetTempPath()).Exists, new FileState(Path.GetTempPath()).FileExists); 340Assert.Equal(new FileInfo(Path.GetTempPath()).IsReadOnly, new FileState(Path.GetTempPath()).IsReadOnly); 346Assert.Equal(new FileInfo(Path.GetTempPath()).LastWriteTime, new FileState(Path.GetTempPath()).LastWriteTime); 352Assert.Equal(new FileInfo(Path.GetTempPath()).LastWriteTimeUtc, new FileState(Path.GetTempPath()).LastWriteTimeUtcFast); 358Helpers.VerifyAssertThrowsSameWay(delegate () { var x = new FileInfo(Path.GetTempPath()).Length; }, delegate () { var x = new FileState(Path.GetTempPath()).Length; }); 368Assert.Equal(new FileInfo(file).LastWriteTime, new FileState(file).LastWriteTime); 378Assert.Equal(new FileInfo(file).LastWriteTimeUtc, new FileState(file).LastWriteTimeUtcFast); 386Helpers.VerifyAssertThrowsSameWay(delegate () { var x = new FileInfo(file).Length; }, delegate () { var x = new FileState(file).Length; });
FindUnderPath_Tests.cs (1)
74testFile = new FileInfo(fileName);
Move_Tests.cs (12)
33FileInfo file = new FileInfo(sourceFile); 53Assert.True(((new FileInfo(destinationFile)).Attributes & FileAttributes.ReadOnly) == 0); // should have cleared r/o bit 78FileInfo file = new FileInfo(sourceFile); 99Assert.True(((new FileInfo(destinationFile)).Attributes & FileAttributes.ReadOnly) == 0); // should have cleared r/o bit 105FileInfo file = new FileInfo(sourceFile); 221FileInfo file = new FileInfo(destinationFile); 241Assert.True(((new FileInfo(destinationFile)).Attributes & FileAttributes.ReadOnly) != 0); // should still be r/o 247FileInfo file = new FileInfo(destinationFile); 328FileInfo file = new FileInfo(destinationFile); 349Assert.True(((new FileInfo(destinationFile)).Attributes & FileAttributes.ReadOnly) == 0); // readonly bit should not be set 382FileInfo file = new FileInfo(destinationFile); 403Assert.True(((new FileInfo(destinationFile)).Attributes & FileAttributes.ReadOnly) == 0); // should have cleared r/o bit
Unzip_Tests.cs (2)
31new FileInfo(file1.Path).IsReadOnly = true; 184new FileInfo(file1.Path).IsReadOnly = true;
XslTransformation_Tests.cs (4)
977Assert.NotEqual(new FileInfo(xmlMultiPaths[0].ItemSpec).Length, new FileInfo(xmlMultiPaths[1].ItemSpec).Length); 978Assert.NotEqual(new FileInfo(outputMultiPaths[0].ItemSpec).Length, new FileInfo(outputMultiPaths[1].ItemSpec).Length);
Microsoft.Build.UnitTests.Shared (3)
EnvironmentProvider.cs (2)
91FileInfo fi = new FileInfo(dotnetExeFromPath); 95fi = new FileInfo(dotnetExeFromPath);
TestEnvironment.cs (1)
506foreach (FileInfo file in newFiles.Except(_originalFiles).Select(f => new FileInfo(f)))
Microsoft.Build.Utilities.Core (5)
BuildEnvironmentHelper.cs (1)
559currentMSBuildExeFile = new FileInfo(currentMSBuildExePath);
FileUtilities.cs (2)
196FileInfo file = new(testFilePath); 999fileInfo = new FileInfo(filePath);
ToolLocationHelper.cs (2)
3363bool exists = new FileInfo(filePath).Exists; 3531bool exists = new FileInfo(filePath).Exists;
Microsoft.CodeAnalysis (4)
DiagnosticAnalyzer\ShadowCopyAnalyzerPathResolver.cs (1)
240ClearReadOnlyFlagOnFile(new FileInfo(shadowCopyPath));
FileSystem\FileUtilities.cs (2)
417var info = new FileInfo(fullPath); 440var info = new FileInfo(fullPath);
FileSystem\PathUtilities.cs (1)
771var fileInfo = new FileInfo(fullPath);
Microsoft.CodeAnalysis.CodeStyle (3)
src\Compilers\Core\Portable\FileSystem\FileUtilities.cs (2)
417var info = new FileInfo(fullPath); 440var info = new FileInfo(fullPath);
src\Compilers\Core\Portable\FileSystem\PathUtilities.cs (1)
771var fileInfo = new FileInfo(fullPath);
Microsoft.CodeAnalysis.CSharp.CommandLine.UnitTests (2)
CommandLineTests.cs (2)
8797Assert.True(new FileInfo(exe.Path).Length < oldSize); 8798Assert.True(new FileInfo(pdb.Path).Length < oldSize);
Microsoft.CodeAnalysis.Features (6)
EmbeddedLanguages\StackFrame\StackFrameLexer.cs (1)
265var fileInfo = new FileInfo(str);
MetadataAsSource\DecompilationMetadataAsSourceFileProvider.cs (1)
203new FileInfo(fileInfo.TemporaryFilePath).IsReadOnly = true;
PdbSourceDocument\PdbSourceDocumentLoaderService.cs (1)
98new FileInfo(filePath).IsReadOnly = true;
SymbolSearch\Windows\SymbolSearchUpdateEngine.Update.cs (3)
182var databaseFileInfo = new FileInfo( 380IOUtilities.PerformIO(() => _service._ioService.Delete(new FileInfo(tempFilePath))); 386=> new FileInfo(Path.ChangeExtension(databaseFileInfo.FullName, ".bin"));
Microsoft.CodeAnalysis.InteractiveHost (3)
src\Compilers\Core\Portable\FileSystem\FileUtilities.cs (2)
417var info = new FileInfo(fullPath); 440var info = new FileInfo(fullPath);
src\Compilers\Core\Portable\FileSystem\PathUtilities.cs (1)
771var fileInfo = new FileInfo(fullPath);
Microsoft.CodeAnalysis.LanguageServer.UnitTests (1)
ExportProviderBuilderTests.cs (1)
143var fileInfo = new FileInfo(tempFile.Path);
Microsoft.CodeAnalysis.Scripting (1)
Hosting\AssemblyLoader\MetadataShadowCopyProvider.cs (1)
617StripReadOnlyAttributeFromFile(new FileInfo(shadowCopyPath));
Microsoft.CodeAnalysis.Test.Utilities (1)
AssemblyLoadTestFixture.cs (1)
547var fileInfo = new FileInfo(tempFile.Path);
Microsoft.CodeAnalysis.Workspaces (4)
src\Compilers\Core\Portable\DiagnosticAnalyzer\ShadowCopyAnalyzerPathResolver.cs (1)
240ClearReadOnlyFlagOnFile(new FileInfo(shadowCopyPath));
src\Compilers\Core\Portable\FileSystem\FileUtilities.cs (2)
417var info = new FileInfo(fullPath); 440var info = new FileInfo(fullPath);
src\Compilers\Core\Portable\FileSystem\PathUtilities.cs (1)
771var fileInfo = new FileInfo(fullPath);
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (3)
src\Compilers\Core\Portable\FileSystem\FileUtilities.cs (2)
417var info = new FileInfo(fullPath); 440var info = new FileInfo(fullPath);
src\Compilers\Core\Portable\FileSystem\PathUtilities.cs (1)
771var fileInfo = new FileInfo(fullPath);
Microsoft.Data.Analysis.Tests (1)
test\Microsoft.ML.TestFramework\BaseTestClass.cs (1)
55var currentAssemblyLocation = new FileInfo(typeof(BaseTestClass).Assembly.Location);
Microsoft.DotNet.Build.Tasks.Feed (3)
src\AzureStorageExtensions.cs (1)
35var localFileSize = new FileInfo(file).Length;
src\PushToBuildStorage.cs (2)
564FileInfo destFile = new(destFileName); 598if (new FileInfo(sourceFileName).IsReadOnly)
Microsoft.DotNet.Build.Tasks.Packaging (1)
PackageIndex.cs (1)
38packageIndexFiles.Select(packageIndexFile => new FileInfo(packageIndexFile))
Microsoft.DotNet.Build.Tasks.Packaging.Tests (2)
PackageIndexTests.cs (2)
52long previousLength = new FileInfo(packageIndexFile).Length; 56var newFileInfo = new FileInfo(packageIndexFile);
Microsoft.DotNet.Build.Tasks.Workloads (1)
Swix\MsiSwixProject.wix.cs (1)
112FileInfo fileInfo = new(_msi.ItemSpec);
Microsoft.DotNet.Helix.JobSender (3)
Payloads\ArchivePayload.cs (2)
21Archive = new FileInfo(pathToArchive); 36var alreadyUploadedFile = new FileInfo($"{Archive.FullName}.payload");
Payloads\DirectoryPayload.cs (1)
46var alreadyUploadedFile = new FileInfo(basePath + ".payload");
Microsoft.DotNet.Helix.Sdk (1)
CommandPayload.cs (1)
56var scriptFile = new FileInfo(Path.Combine(Directory.FullName, name));
Microsoft.DotNet.Open.Api.Tools.Tests (41)
OpenApiAddFileTests.cs (6)
85var csproj = new FileInfo(project.Project.Path); 118var csproj = new FileInfo(project.Project.Path); 138var csproj = new FileInfo(project.Project.Path); 159var csproj = new FileInfo(project.Project.Path); 179var csproj = new FileInfo(project.Project.Path); 205var csproj = new FileInfo(project.Project.Path);
OpenApiAddProjectTests.cs (2)
44using var csprojStream = new FileInfo(project.Project.Path).OpenRead(); 102using var csprojStream = new FileInfo(project.Project.Path).OpenRead();
OpenApiAddURLTests.cs (26)
29using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 40using (var jsonStream = new FileInfo(jsonFile).OpenRead()) 62using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 73using (var jsonStream = new FileInfo(jsonFile).OpenRead()) 95using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 106using (var jsonStream = new FileInfo(jsonFile).OpenRead()) 128using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 139using (var jsonStream = new FileInfo(jsonFile).OpenRead()) 160using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 171using (var jsonStream = new FileInfo(jsonFile).OpenRead()) 193using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 204using (var jsonStream = new FileInfo(firstJsonFile).OpenRead()) 219using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 232using (var jsonStream = new FileInfo(secondJsonFile).OpenRead()) 253using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 264using (var jsonStream = new FileInfo(resultFile).OpenRead()) 285using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 296using (var jsonStream = new FileInfo(resultFile).OpenRead()) 317using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 328using (var jsonStream = new FileInfo(resultFile).OpenRead()) 351using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 362using (var jsonStream = new FileInfo(resultFile).OpenRead()) 376using (var csprojStream = new FileInfo(project.Project.Path).OpenRead()) 387using (var jsonStream = new FileInfo(resultFile).OpenRead()) 411var csproj = new FileInfo(project.Project.Path); 437using (var csprojStream = new FileInfo(project.Project.Path).OpenRead())
OpenApiRemoveTests.cs (7)
32var csproj = new FileInfo(Path.Join(_tempDir.Root, "testproj.csproj")); 47csproj = new FileInfo(Path.Join(_tempDir.Root, "testproj.csproj")); 75var csproj = new FileInfo(Path.Join(_tempDir.Root, "testproj.csproj")); 90csproj = new FileInfo(Path.Join(_tempDir.Root, "testproj.csproj")); 124using (var csprojStream = new FileInfo(Path.Join(_tempDir.Root, "testproj.csproj")).OpenRead()) 138using (var csprojStream = new FileInfo(Path.Join(_tempDir.Root, "testproj.csproj")).OpenRead()) 177var csproj = new FileInfo(Path.Join(_tempDir.Root, "testproj.csproj"));
Microsoft.DotNet.RemoteExecutor (1)
RemoteInvokeHandle.cs (1)
229FileInfo exceptionFileInfo = new FileInfo(Options.ExceptionFile);
Microsoft.DotNet.SignTool (1)
src\BatchSignUtil.cs (1)
247FileInfo fileInfo = new FileInfo(file.FullPath);
Microsoft.DotNet.SwaggerGenerator.CmdLine (1)
Program.cs (1)
108var file = new FileInfo(fullPath);
Microsoft.DotNet.SwaggerGenerator.CodeGenerator (1)
Languages\Language.cs (1)
41var file = new FileInfo(path);
Microsoft.DotNet.SwaggerGenerator.MSBuild (1)
GenerateSwaggerCode.cs (1)
86var file = new FileInfo(fullPath);
Microsoft.DotNet.XUnitAssert.Tests (8)
EquivalenceAssertsTests.cs (8)
1549 var expected = new FileInfo(assemblyPath); 1550 var actual = new FileInfo(assemblyParentPath); 1562 var expected = new FileInfo(assembly); 1563 var actual = new FileInfo(assembly); 1571 var expected = new FileInfo(typeof(SpecialCases).Assembly.Location); 1572 var actual = new FileInfo(typeof(Assert).Assembly.Location); 1584 var expected = new FileInfo(location); 1602 var expected = new { Info = new FileInfo(location) };
Microsoft.Extensions.AI.Evaluation.Reporting (3)
Storage\DiskBasedResultStore.cs (3)
97var resultFile = new FileInfo(Path.Combine(resultDir.FullName, $"{result.IterationName}.json")); 143new FileInfo(Path.Combine(_resultsRootPath, executionName, scenarioName, $"{iterationName}.json")); 338var resultFile = new FileInfo(Path.Combine(scenarioDir.FullName, $"{iterationName}.json"));
Microsoft.Extensions.Diagnostics.ResourceMonitoring (27)
Linux\LinuxUtilizationParserCgroupV1.cs (10)
26private static readonly FileInfo _cpuCfsQuotaUs = new("/sys/fs/cgroup/cpu/cpu.cfs_quota_us"); 31private static readonly FileInfo _cpuCfsPeriodUs = new("/sys/fs/cgroup/cpu/cpu.cfs_period_us"); 40private static readonly FileInfo _procStat = new("/proc/stat"); 45private static readonly FileInfo _memInfo = new("/proc/meminfo"); 50private static readonly FileInfo _cpuSetCpus = new("/sys/fs/cgroup/cpuset/cpuset.cpus"); 55private static readonly FileInfo _memoryLimitInBytes = new("/sys/fs/cgroup/memory/memory.limit_in_bytes"); 63private static readonly FileInfo _memoryUsageInBytes = new("/sys/fs/cgroup/memory/memory.usage_in_bytes"); 72private static readonly FileInfo _memoryStat = new("/sys/fs/cgroup/memory/memory.stat"); 81private static readonly FileInfo _cpuacctUsage = new("/sys/fs/cgroup/cpuacct/cpuacct.usage"); 86private static readonly FileInfo _cpuPodWeight = new("/sys/fs/cgroup/cpu/cpu.shares");
Linux\LinuxUtilizationParserCgroupV2.cs (15)
34private static readonly FileInfo _cpuCfsQuaotaPeriodUs = new("/sys/fs/cgroup/cpu.max"); 43private static readonly FileInfo _procStat = new("/proc/stat"); 48private static readonly FileInfo _memInfo = new("/proc/meminfo"); 54private static readonly FileInfo _cpuSetCpus = new("/sys/fs/cgroup/cpuset.cpus.effective"); 59private static readonly FileInfo _memoryLimitInBytes = new("/sys/fs/cgroup/memory.max"); 67private static readonly FileInfo _memoryUsageInBytes = new("/sys/fs/cgroup/memory.current"); 76private static readonly FileInfo _memoryStat = new("/sys/fs/cgroup/memory.stat"); 85private static readonly FileInfo _cpuacctUsage = new("/sys/fs/cgroup/cpu.stat"); 90private static readonly FileInfo _cpuPodWeight = new("/sys/fs/cgroup/cpu.weight"); 92private static readonly FileInfo _cpuCgroupInfoFile = new("/proc/self/cgroup"); 153FileInfo cpuUsageFile = new(GetCgroupPath(CpuStat)); 226FileInfo cpuLimitsFile = new(GetCgroupPath(CpuLimit)); 237FileInfo cpuLimitsFile = new(GetCgroupPath(CpuLimit)); 261FileInfo cpuRequestsFile = new(GetCgroupPath(CpuRequest)); 318FileInfo memoryUsageInBytesFile = new(Path.Combine(path, "memory.current"));
Linux\Network\LinuxNetworkUtilizationParser.cs (2)
23private static readonly FileInfo _tcp = new("/proc/net/tcp"); 28private static readonly FileInfo _tcp6 = new("/proc/net/tcp6");
Microsoft.Extensions.Diagnostics.ResourceMonitoring.Tests (188)
Linux\AcceptanceTest.cs (63)
115{ new FileInfo("/sys/fs/cgroup/memory/memory.limit_in_bytes"), "100000" }, 116{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 117{ new FileInfo("/sys/fs/cgroup/cpuacct/cpuacct.usage"), "102312"}, 118{ new FileInfo("/proc/meminfo"), "MemTotal: 102312 kB"}, 119{ new FileInfo("/sys/fs/cgroup/cpuset/cpuset.cpus"), "0-19"}, 120{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_quota_us"), "12"}, 121{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_period_us"), "6"}, 122{ new FileInfo("/sys/fs/cgroup/cpu/cpu.shares"), "1024"} 164{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 165{ new FileInfo("/sys/fs/cgroup/cpu.stat"), "usage_usec 102312\nnr_periods 50"}, 166{ new FileInfo("/proc/meminfo"), "MemTotal: 102312 kB"}, 167{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "0-1"}, 168{ new FileInfo("/sys/fs/cgroup/cpu.max"), "20000 100000"}, 169{ new FileInfo("/sys/fs/cgroup/cpu.weight"), "4"}, 170{ new FileInfo("/sys/fs/cgroup/memory.max"), "100000" } 198{ new FileInfo("/sys/fs/cgroup/memory/memory.limit_in_bytes"), "100000" }, 199{ new FileInfo("/sys/fs/cgroup/memory/memory.usage_in_bytes"), "450000" }, 200{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 201{ new FileInfo("/sys/fs/cgroup/cpuacct/cpuacct.usage"), "102312"}, 202{ new FileInfo("/proc/meminfo"), "MemTotal: 102312 kB"}, 203{ new FileInfo("/sys/fs/cgroup/cpuset/cpuset.cpus"), "0-19"}, 204{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_quota_us"), "24"}, 205{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_period_us"), "6"}, 206{ new FileInfo("/sys/fs/cgroup/cpu/cpu.shares"), "2048"}, 207{ new FileInfo("/sys/fs/cgroup/memory/memory.stat"), "total_inactive_file 100"}, 253fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/memory/memory.usage_in_bytes"), "50100"); 254fileSystem.ReplaceFileContent(new FileInfo("/proc/stat"), "cpu 11 10 10 10 10 10 10 10 10 10"); 255fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/cpuacct/cpuacct.usage"), "112312"); 284{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 285{ new FileInfo("/sys/fs/cgroup/cpu.stat"), "usage_usec 102\nnr_periods 50"}, 286{ new FileInfo("/sys/fs/cgroup/memory.max"), "1048576" }, 287{ new FileInfo("/proc/meminfo"), "MemTotal: 1024 kB"}, 288{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "0-19"}, 289{ new FileInfo("/sys/fs/cgroup/cpu.max"), "40000 10000"}, 290{ new FileInfo("/sys/fs/cgroup/cpu.weight"), "79"}, // equals to 2046,9 CPU shares (cgroups v1) which is ~2 CPU units (2 * 1024), so have to use Math.Round() in Assertions down below. 337fileSystem.ReplaceFileContent(new FileInfo("/proc/stat"), "cpu 11 10 10 10 10 10 10 10 10 10"); 338fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/cpu.stat"), "usage_usec 112\nnr_periods 56"); 339fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/memory.current"), "524298"); 340fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/memory.stat"), "inactive_file 10"); 371{ new FileInfo("/proc/self/cgroup"), "0::/fakeslice"}, 372{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 373{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.stat"), "usage_usec 1020000\nnr_periods 50"}, 374{ new FileInfo("/sys/fs/cgroup/memory.max"), "1048576" }, 375{ new FileInfo("/proc/meminfo"), "MemTotal: 1024 kB"}, 376{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "0-19"}, 377{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.max"), "40000 10000"}, 378{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.weight"), "79"}, 418fileSystem.ReplaceFileContent(new FileInfo("/proc/stat"), "cpu 11 10 10 10 10 10 10 10 10 10"); 419fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/fakeslice/cpu.stat"), "usage_usec 1120000\nnr_periods 56"); 420fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/memory.current"), "524298"); 421fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/memory.stat"), "inactive_file 10"); 447{ new FileInfo("/proc/self/cgroup"), "0::/fakeslice"}, 448{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 449{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.stat"), "usage_usec 1020000\nnr_periods 50"}, 450{ new FileInfo("/sys/fs/cgroup/memory.max"), "1048576" }, 451{ new FileInfo("/proc/meminfo"), "MemTotal: 1024 kB"}, 452{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "0-19"}, 453{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.max"), "40000 10000"}, 454{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.weight"), "79"}, 498fileSystem.ReplaceFileContent(new FileInfo("/proc/stat"), "cpu 11 10 10 10 10 10 10 10 10 10"); 499fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/fakeslice/cpu.stat"), "usage_usec 1120000\nnr_periods 56"); 500fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/memory.current"), "524298"); 501fileSystem.ReplaceFileContent(new FileInfo("/sys/fs/cgroup/memory.stat"), "inactive_file 10");
Linux\LinuxCountersTests.cs (6)
24new FileInfo("/proc/net/tcp"), 51new FileInfo("/proc/net/tcp6"), 120new FileInfo("/proc/net/tcp"), 126new FileInfo("/proc/net/tcp6"), 153fileSystem.ReplaceFileContent(new FileInfo("/proc/net/tcp"), tcpFile); 154fileSystem.ReplaceFileContent(new FileInfo("/proc/net/tcp6"), tcp6File);
Linux\LinuxNetworkUtilizationParserTests.cs (6)
37new FileInfo("/proc/net/tcp"), 42new FileInfo("/proc/net/tcp6"), 63fileSystem.ReplaceFileContent(new FileInfo("/proc/net/tcp"), tcpFile); 64fileSystem.ReplaceFileContent(new FileInfo("/proc/net/tcp6"), tcp6File); 75fileSystem.ReplaceFileContent(new FileInfo("/proc/net/tcp"), tcpFile); 76fileSystem.ReplaceFileContent(new FileInfo("/proc/net/tcp6"), tcp6File);
Linux\LinuxUtilizationParserCgroupV1Tests.cs (25)
85{ new FileInfo("/sys/fs/cgroup/memory/memory.stat"), content } 111{ new FileInfo("/sys/fs/cgroup/memory/memory.stat"), "total_inactive_file 0" }, 112{ new FileInfo("/sys/fs/cgroup/memory/memory.usage_in_bytes"), content } 130{ new FileInfo("/sys/fs/cgroup/memory/memory.stat"), $"total_inactive_file {inactive}" }, 131{ new FileInfo("/sys/fs/cgroup/memory/memory.usage_in_bytes"), total.ToString(CultureInfo.CurrentCulture) } 157{ new FileInfo("/proc/meminfo"), totalMemory }, 177{ new FileInfo("/proc/meminfo"), $"MemTotal: {value} {unit}" }, 202{ new FileInfo("/sys/fs/cgroup/cpuset/cpuset.cpus"), content }, 203{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_quota_us"), "-1" }, 204{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_period_us"), "-1" } 229{ new FileInfo("/sys/fs/cgroup/cpuset/cpuset.cpus"), content }, 230{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_quota_us"), "12" }, 231{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_period_us"), "-1" } 250{ new FileInfo("/sys/fs/cgroup/cpuset/cpuset.cpus"), "@" }, 251{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_quota_us"), quota }, 252{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_period_us"), period } 279{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_quota_us"), quota }, 280{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_period_us"), period } 295{ new FileInfo("/proc/stat"), "cpu 2569530 36700 245693 4860924 82283 0 4360 0 0 0" } 309{ new FileInfo("/sys/fs/cgroup/memory/memory.usage_in_bytes"), "32493514752\r\n" }, 310{ new FileInfo("/sys/fs/cgroup/memory/memory.stat"), "total_inactive_file 100" } 330{ new FileInfo("/proc/stat"), content } 347{ new FileInfo("/sys/fs/cgroup/cpu/cpu.shares"), content }, 362{ new FileInfo("/proc/stat"), "cpu 6163 0 3853 4222848 614 0 1155 0 0 0\r\ncpu0 240 0 279 210987 59 0 927 0 0 0" }, 366{ new FileInfo("/proc/stat"), "cpu 9137 0 9296 13972503 1148 0 2786 0 0 0\r\ncpu0 297 0 431 698663 59 0 2513 0 0 0" },
Linux\LinuxUtilizationParserCgroupV2Tests.cs (41)
89{ new FileInfo("/sys/fs/cgroup/memory.stat"), content } 113{ new FileInfo("/sys/fs/cgroup/memory.stat"), "inactive_file 14340" }, 114{ new FileInfo("/sys/fs/cgroup/memory.current"), content } 130{ new FileInfo("/sys/fs/cgroup/memory.max"), content }, 131{ new FileInfo("/proc/meminfo"), "MemTotal: 131637608 kB" } 148{ new FileInfo("/sys/fs/cgroup/memory.max"), content }, 163{ new FileInfo("/sys/fs/cgroup/system.slice/memory.current"), "dasda"}, 179{ new FileInfo("/sys/fs/cgroup/system.slice/memory.current"), "5342342"}, 190{ new FileInfo("/sys/fs/cgroup/system.slice/memory.current"), "0"}, 206{ new FileInfo("/sys/fs/cgroup/memory.stat"), $"inactive_file {inactive}" }, 207{ new FileInfo("/sys/fs/cgroup/memory.current"), total.ToString(CultureInfo.CurrentCulture) } 232{ new FileInfo("/proc/meminfo"), totalMemory }, 250{ new FileInfo("/proc/meminfo"), $"MemTotal: {value} {unit}" }, 275{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), content }, 276{ new FileInfo("/sys/fs/cgroup/cpu.max"), "-1" }, 292{ new FileInfo("/sys/fs/cgroup/cpu.max"), "200000 100000" }, 293{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.max"), "200000 100000" }, 294{ new FileInfo("/proc/self/cgroup"), slicepath } 310{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.weight"), content }, 311{ new FileInfo("/proc/self/cgroup"), "0::/fakeslice" } 325{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "0,1,2" }, 326{ new FileInfo("/sys/fs/cgroup/cpu.max"), "max 100000" }, 351{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), content }, 352{ new FileInfo("/sys/fs/cgroup/cpu.max"), "-1" } 366{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "@" }, 367{ new FileInfo("/sys/fs/cgroup/cpu.max"), "-1" } 392{ new FileInfo("/sys/fs/cgroup/cpu.max"), $"{quota} {period}"}, 406{ new FileInfo("/proc/stat"), "cpu 2569530 36700 245693 4860924 82283 0 4360 0 0 0" } 422{ new FileInfo("/sys/fs/cgroup/cpu.stat"), content }, 423{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.stat"), content }, 424{ new FileInfo("/proc/self/cgroup"), slicepath } 441{ new FileInfo("/sys/fs/cgroup/memory.current"), "32493514752" }, 442{ new FileInfo("/sys/fs/cgroup/memory.stat"), "inactive_file 100" } 462{ new FileInfo("/proc/stat"), content } 479{ new FileInfo("/sys/fs/cgroup/cpu.stat"), $"{content} {value}"}, 496{ new FileInfo("/sys/fs/cgroup/cpu.stat"), $"usage_usec {value}"}, 514{ new FileInfo("/sys/fs/cgroup/cpu.weight"), content }, 530{ new FileInfo("/sys/fs/cgroup/cpu.weight"), content }, 547{ new FileInfo("/proc/self/cgroup"), content }, 561{ new FileInfo("/proc/stat"), "cpu 6163 0 3853 4222848 614 0 1155 0 0 0\r\ncpu0 240 0 279 210987 59 0 927 0 0 0" }, 565{ new FileInfo("/proc/stat"), "cpu 9137 0 9296 13972503 1148 0 2786 0 0 0\r\ncpu0 297 0 431 698663 59 0 2513 0 0 0" },
Linux\LinuxUtilizationProviderTests.cs (38)
39{ new FileInfo("/sys/fs/cgroup/memory/memory.limit_in_bytes"), "9223372036854771712" }, 40{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 41{ new FileInfo("/sys/fs/cgroup/cpuacct/cpuacct.usage"), "50"}, 42{ new FileInfo("/proc/meminfo"), "MemTotal: 1024 kB"}, 43{ new FileInfo("/sys/fs/cgroup/cpuset/cpuset.cpus"), "0-19"}, 44{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_quota_us"), "60"}, 45{ new FileInfo("/sys/fs/cgroup/cpu/cpu.cfs_period_us"), "6"}, 46{ new FileInfo("/sys/fs/cgroup/memory/memory.stat"), "total_inactive_file 0"}, 47{ new FileInfo("/sys/fs/cgroup/memory/memory.usage_in_bytes"), "524288"}, 48{ new FileInfo("/sys/fs/cgroup/cpu/cpu.shares"), "1024"}, 109{ new FileInfo("/sys/fs/cgroup/memory.max"), "9223372036854771712" }, 110{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 111{ new FileInfo("/sys/fs/cgroup/cpu.stat"), "usage_usec 102312\nnr_periods 50"}, 112{ new FileInfo("/proc/meminfo"), "MemTotal: 1024 kB"}, 113{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "0-19"}, 114{ new FileInfo("/sys/fs/cgroup/cpu/cpu.max"), "20000 100000"}, 115{ new FileInfo("/sys/fs/cgroup/memory.stat"), "inactive_file 312312"}, 116{ new FileInfo("/sys/fs/cgroup/memory.current"), "524288423423"}, 117{ new FileInfo("/sys/fs/cgroup/cpu.weight"), "4"}, 177{ new FileInfo("/sys/fs/cgroup/memory.max"), "9223372036854771712" }, 178{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 179{ new FileInfo("/sys/fs/cgroup/cpu.stat"), "usage_usec 102312\nnr_periods 50"}, 180{ new FileInfo("/proc/meminfo"), "MemTotal: 1024 kB"}, 181{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "0-19"}, 182{ new FileInfo("/sys/fs/cgroup/cpu/cpu.max"), "20000 100000"}, 183{ new FileInfo("/sys/fs/cgroup/memory.stat"), "inactive_file 312312"}, 184{ new FileInfo("/sys/fs/cgroup/memory.current"), "524288423423"}, 185{ new FileInfo("/sys/fs/cgroup/cpu.weight"), "4"}, 223{ new FileInfo("/proc/self/cgroup"), "0::/fakeslice" }, 224{ new FileInfo("/sys/fs/cgroup/memory.max"), "9223372036854771712" }, 225{ new FileInfo("/proc/stat"), "cpu 10 10 10 10 10 10 10 10 10 10"}, 226{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.stat"), "usage_usec 102312\nnr_periods 50"}, 227{ new FileInfo("/proc/meminfo"), "MemTotal: 1024 kB"}, 228{ new FileInfo("/sys/fs/cgroup/cpuset.cpus.effective"), "0-19"}, 229{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.max"), "20000 100000"}, 230{ new FileInfo("/sys/fs/cgroup/memory.stat"), "inactive_file 312312"}, 231{ new FileInfo("/sys/fs/cgroup/memory.current"), "524288423423"}, 232{ new FileInfo("/sys/fs/cgroup/fakeslice/cpu.weight"), "4"},
Linux\OSFileSystemTests.cs (9)
32var file = new FileInfo("fixtures/status"); 45var file = new FileInfo("fixtures/cpuacct.stat"); 64var file = new FileInfo("fixtures/FileWithRChars"); 75var file = new FileInfo("fixtures/tcpacct.stat"); 96var fileInfo = new FileInfo("test.txt"); 124var fileInfo = new FileInfo("test.txt"); 146var fileInfo = new FileInfo("test.txt"); 174var fileInfo = new FileInfo("nonexistent.txt"); 196var fileInfo = new FileInfo("test.txt");
Microsoft.Extensions.FileProviders.Physical (4)
Internal\FileSystemInfoHelper.cs (1)
35var fileInfo = new FileInfo(filePath);
PhysicalFileProvider.cs (1)
285var fileInfo = new FileInfo(fullPath);
PhysicalFilesWatcher.cs (2)
189var pollingChangeToken = new PollingFileChangeToken(new FileInfo(Path.Combine(_root, filePath))); 342var fileSystemInfo = new FileInfo(fullPath);
Microsoft.Extensions.FileSystemGlobbing (1)
Abstractions\DirectoryInfoWrapper.cs (1)
103=> new FileInfoWrapper(new FileInfo(Path.Combine(_directoryInfo.FullName, name)));
Microsoft.Extensions.Logging.AzureAppServices (1)
FileLoggerProvider.cs (1)
46var fileInfo = new FileInfo(fullName);
Microsoft.Maui.Resizetizer (7)
CreatePartialInfoPlistTask.cs (1)
47 var fontFile = new FileInfo(font.ItemSpec);
ResizeImageInfo.cs (2)
81 var fileInfo = new FileInfo(image.GetMetadata("FullPath")); 120 var fgFileInfo = new FileInfo(fgFile);
Resizer.cs (4)
56 var fileInfo = new FileInfo(destination); 80 var fileIn = new FileInfo(inputFile); 81 var fileOut = new FileInfo(outputFile); 82 var fileInputs = inputsFile is null ? null : new FileInfo(inputsFile);
Microsoft.ML.AutoML (3)
Experiment\Runners\RunnerUtil.cs (1)
58new FileInfo(Path.Combine(modelDirectory.FullName, $"Model{iterationNum}_{foldNum}.zip"));
Experiment\Runners\TrainValidateRunner.cs (1)
66new FileInfo(Path.Combine(modelDirectory.FullName, $"Model{iterationNum}.zip"));
Utils\UserInputValidationUtil.cs (1)
171var fileInfo = new FileInfo(path);
Microsoft.ML.AutoML.Tests (2)
DatasetUtil.cs (2)
212var fileInfo = new FileInfo(relativeFilePath); 236Path.Combine(new FileInfo(typeof(
Microsoft.ML.IntegrationTests (1)
IntegrationTestBaseClass.cs (1)
47var currentAssemblyLocation = new FileInfo(typeof(IntegrationTestBaseClass).Assembly.Location);
Microsoft.ML.PerformanceTests (2)
ImageClassificationBench.cs (2)
165var currentSize = new FileInfo(relativeFilePath).Length; 208FileInfo dataRoot = new FileInfo(typeof(
Microsoft.ML.Samples (4)
Dynamic\Trainers\MulticlassClassification\ImageClassification\ImageClassificationDefault.cs (1)
309FileInfo _dataRoot = new FileInfo(typeof(
Dynamic\Trainers\MulticlassClassification\ImageClassification\LearningRateSchedulingCifarResnetTransferLearning.cs (1)
350FileInfo _dataRoot = new FileInfo(typeof(
Dynamic\Trainers\MulticlassClassification\ImageClassification\ResnetV2101TransferLearningEarlyStopping.cs (1)
306FileInfo _dataRoot = new FileInfo(typeof(
Dynamic\Trainers\MulticlassClassification\ImageClassification\ResnetV2101TransferLearningTrainTestSplit.cs (1)
327FileInfo _dataRoot = new FileInfo(typeof(
Microsoft.ML.Samples.GPU (4)
docs\samples\Microsoft.ML.Samples\Dynamic\Trainers\MulticlassClassification\ImageClassification\ImageClassificationDefault.cs (1)
309FileInfo _dataRoot = new FileInfo(typeof(
docs\samples\Microsoft.ML.Samples\Dynamic\Trainers\MulticlassClassification\ImageClassification\LearningRateSchedulingCifarResnetTransferLearning.cs (1)
350FileInfo _dataRoot = new FileInfo(typeof(
docs\samples\Microsoft.ML.Samples\Dynamic\Trainers\MulticlassClassification\ImageClassification\ResnetV2101TransferLearningEarlyStopping.cs (1)
306FileInfo _dataRoot = new FileInfo(typeof(
docs\samples\Microsoft.ML.Samples\Dynamic\Trainers\MulticlassClassification\ImageClassification\ResnetV2101TransferLearningTrainTestSplit.cs (1)
327FileInfo _dataRoot = new FileInfo(typeof(
Microsoft.ML.Sweeper (1)
ConfigRunner.cs (1)
211if (File.Exists(errorFile) && new FileInfo(errorFile).Length == 0)
Microsoft.ML.TestFramework (4)
BaseTestClass.cs (1)
55var currentAssemblyLocation = new FileInfo(typeof(BaseTestClass).Assembly.Location);
CopyAction.cs (3)
26FileInfo file = new FileInfo(oldPath); 27FileInfo destFile = new FileInfo(newPath); 45var testDirectory = new FileInfo(typeof(CopyAction).Assembly.Location).Directory;
Microsoft.ML.Tokenizers.Data.Tests (1)
test\Microsoft.ML.Tokenizers.Tests\Utils.cs (1)
25var fileInfo = new FileInfo(fileName);
Microsoft.ML.Tokenizers.Tests (1)
Utils.cs (1)
25var fileInfo = new FileInfo(fileName);
Microsoft.VisualBasic.Core (6)
Microsoft\VisualBasic\CompilerServices\VB6File.vb (1)
392m_sFullPath = (New FileInfo(sPath)).FullName
Microsoft\VisualBasic\FileSystem.vb (5)
308Return (New FileInfo(PathName)).LastWriteTime 319Return (New FileInfo(PathName)).Length 353Dim f As New FileInfo(PathName) 1323Result = (New FileInfo(sPath)).FullName 1392FileName = (New FileInfo(FileName)).FullName
Microsoft.VisualBasic.Tests (3)
Microsoft\VisualBasic\MyServices\FileSystemProxyTests.cs (3)
370var FileInfoFromSystemIO = new FileInfo(TestFile); 484Assert.Equal(0, (new FileInfo(TempFile)).Length); 618CreateTestFile(DestData, PathFromBase: null, TestFileName: (new FileInfo(SourceFileNameWithPath)).Name);
MSBuild (3)
BuildEnvironmentHelper.cs (1)
559currentMSBuildExeFile = new FileInfo(currentMSBuildExePath);
FileUtilities.cs (2)
196FileInfo file = new(testFilePath); 999fileInfo = new FileInfo(filePath);
MSBuildTaskHost (3)
BuildEnvironmentHelper.cs (1)
559currentMSBuildExeFile = new FileInfo(currentMSBuildExePath);
FileUtilities.cs (2)
196FileInfo file = new(testFilePath); 999fileInfo = new FileInfo(filePath);
PresentationFramework (1)
MS\Internal\IO\Packaging\XpsFilter.cs (1)
640FileInfo fi = new FileInfo(filePath);
PresentationUI (2)
MS\Internal\Documents\Application\DocumentProperties.cs (1)
345FileInfo fileInfo = new FileInfo(filePath);
MS\Internal\Documents\Application\DocumentStream.cs (1)
531FileInfo originalInfo = new FileInfo(original);
ResultsOfTGenerator (2)
Program.cs (2)
206var file = new FileInfo(classFilePath); 292var file = new FileInfo(testFilePath);
RunTests (2)
Program.cs (2)
245ConsoleUtil.WriteLine($"succeeded ({new FileInfo(dumpFilePath).Length} bytes)"); 428long fileSizeInMegabytes = (new FileInfo(dumpFile).Length / 1024) / 1024;
ServerComparison.FunctionalTests (1)
Helpers.cs (1)
19var solutionFileInfo = new FileInfo(Path.Combine(directoryInfo.FullName, "FunctionalTests.slnf"));
System.ComponentModel.TypeConverter (1)
System\ComponentModel\Design\DesigntimeLicenseContext.cs (1)
78string fileName = new FileInfo(location).Name;
System.Configuration.ConfigurationManager (2)
System\Configuration\Internal\InternalConfigHost.cs (2)
214FileInfo info = new FileInfo(streamName); 255FileInfo fi = new FileInfo(streamName);
System.Formats.Tar (2)
System\Formats\Tar\TarEntry.cs (1)
465FileInfo link = new(filePath);
System\Formats\Tar\TarWriter.Unix.cs (1)
41FileSystemInfo info = entryType is TarEntryType.Directory ? new DirectoryInfo(fullPath) : new FileInfo(fullPath);
System.IO.Packaging (1)
System\IO\Packaging\Package.cs (1)
879FileInfo packageFileInfo = new FileInfo(path);
System.Private.CoreLib (2)
src\libraries\System.Private.CoreLib\src\System\IO\FileInfo.cs (1)
192return new FileInfo(destinationFileName);
src\libraries\System.Private.CoreLib\src\System\IO\FileSystem.Unix.cs (1)
718new FileInfo(linkTarget);
System.Runtime.Caching (1)
System\Runtime\Caching\FileChangeNotificationSystem.cs (1)
101FileInfo fileInfo = new FileInfo(filePath);
System.Windows.Forms (4)
System\Windows\Forms\Controls\ListView\ListView.cs (4)
2428fi = new FileInfo(bkImgFileName); 2934FileInfo fi = new(fileName); 3095fi = new FileInfo(_backgroundImageFileName); 3120fi = new FileInfo(bkImgFileName);
System.Windows.Forms.Design (1)
System\Windows\Forms\Design\DocumentDesigner.AxToolboxItem.cs (1)
171FileInfo file = new(path);