eng/build/PlaceholderSimulation.props (9 lines of code) (raw):
<Project>
<!-- PlaceholderSimulation.props
This props file is to be imported only when test placeholder behavior. Importing this file will set up the WebHost to simulate placeholder behavior.
There are integrity checks in this file to ensure correct use:
1. PlaceholderSimulation must be set to 'true' on import and remain 'true' for the entire build.
-->
<PropertyGroup>
<!-- See if this was imported somehow without PlaceholderSimulation=true -->
<_PlaceholderSimulationOriginal>$(PlaceholderSimulation)</_PlaceholderSimulationOriginal>
<DefineConstants>$(DefineConstants)PLACEHOLDER_SIMULATION;</DefineConstants>
</PropertyGroup>
<!-- Verify PlaceholderSimulation remains 'true' for the entire build. -->
<Target Name="_PlaceholderFailWrongValue" AfterTargets="Build" Condition="'$(PlaceholderSimulation)' != 'true'">
<Error Text="Expected 'PlaceholderSimulation' to be 'true'. Actual value: '$(PlaceholderSimulation)'." />
</Target>
</Project>