This repository was archived by the owner on Feb 12, 2025. It is now read-only.
This repository was archived by the owner on Feb 12, 2025. It is now read-only.
Tests: Replace %TEMP% path hardcodings #307
Open
Description
There are several places in unit tests where temporary path is hardcoded, for example:
- project/UnitTests/Core/Config/PreprocessorTest.cs
FAKE_ROOT
- project/UnitTests/Core/IntegrationResultManagerTest.cs
Assert.AreEqual(Platform.IsWindows ? @"c:\temp" : @"/tmp", result.WorkingDirectory);
- project/UnitTests/Core/ProjectTest.cs
Assert.AreEqual(Platform.IsWindows ? @"c:\temp" : @"/tmp", result.WorkingDirectory);
We can use Path.GetTempPath or the env. variables (see the remarks section in the link) to get the temp path without checking the platform.
Metadata
Metadata
Assignees
Labels
No labels