Skip to content

Commit e78d655

Browse files
ElStefanStefan Lampertvbreuss
authored
feat: Add a sample Directory.Build.props (#328)
I added a sample Directory.Build.props on the root path and adapted the CONTRIBUTING.md to simplify activating tests for the `RealFileSystem` Co-authored-by: Stefan Lampert <[email protected]> Co-authored-by: Valentin Breuß <[email protected]>
1 parent 4f4983a commit e78d655

File tree

3 files changed

+11
-1
lines changed

3 files changed

+11
-1
lines changed

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Additionally each push to the `main` branch checks the quality of the unit tests
1515

1616
## Tests
1717
On the build system, unit tests are executed both against the `MockFileSystem` and the `RealFileSystem`. This ensures that the tests verify correct assumptions.
18-
In order to simplify and speedup the development process, per default some tests are disabled in DEBUG mode. These can be enabled by adding a `Directory.Build.props` file in the root directory and set the corresponding constants:
18+
In order to simplify and speedup the development process, per default some tests are disabled in DEBUG mode. These can be enabled by editing the sample [`Directory.Build.props`](https://github.com/Testably/Testably.Abstractions/blob/main/Directory.Build.props) file in the root directory and set the corresponding constants:
1919
- [`ENABLE_REALFILESYSTEMTESTS_IN_DEBUG`](https://github.com/Testably/Testably.Abstractions/blob/main/Tests/Helpers/Testably.Abstractions.Tests.SourceGenerator/ClassGenerators/FileSystemClassGenerator.cs#L59)
2020
If set, the classes for executing tests against the real file system are created also in DEBUG mode.
2121
- [`INCLUDE_LONGRUNNING_TESTS_ALSO_IN_DEBUG_MODE`](https://github.com/Testably/Testably.Abstractions/blob/main/Tests/Helpers/Testably.Abstractions.TestHelpers/Test.cs#L51)

Directory.Build.props

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<Project>
2+
<PropertyGroup>
3+
<!-- Uncomment a line to enable the desired behavior. See https://github.com/Testably/Testably.Abstractions/blob/main/CONTRIBUTING.md#tests for more information! -->
4+
5+
<!--<DefineConstants>$(DefineConstants);ENABLE_REALFILESYSTEMTESTS_IN_DEBUG</DefineConstants>-->
6+
<!--<DefineConstants>$(DefineConstants);INCLUDE_LONGRUNNING_TESTS_ALSO_IN_DEBUG_MODE</DefineConstants>-->
7+
<!--<DefineConstants>$(DefineConstants);SKIP_TESTS_ON_REAL_FILESYSTEM</DefineConstants>-->
8+
</PropertyGroup>
9+
</Project>

Testably.Abstractions.sln

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "_", "_", "{94F99274-3518-45
1111
CODE_OF_CONDUCT.md = CODE_OF_CONDUCT.md
1212
CONTRIBUTING.md = CONTRIBUTING.md
1313
Directory.Packages.props = Directory.Packages.props
14+
Directory.Build.props = Directory.Build.props
1415
Feature.Flags.props = Feature.Flags.props
1516
LICENSE = LICENSE
1617
nuget.config = nuget.config

0 commit comments

Comments
 (0)