99 references to HasUnsavedChanges
Microsoft.Build (3)
Construction\ProjectRootElement.cs (2)
1527if (HasUnsavedChanges || !Equals(saveEncoding, Encoding)) 2134if (HasUnsavedChanges && throwIfUnsavedChanges)
ObjectModelRemoting\ConstructionObjectLinks\ProjectRootElementLink.cs (1)
26/// Access to remote <see cref="ProjectRootElement.HasUnsavedChanges"/>.
Microsoft.Build.Engine.OM.UnitTests (95)
Construction\ConstructionEditing_Tests.cs (11)
39Assert.True(project.HasUnsavedChanges); 58Assert.False(project.HasUnsavedChanges); 380Assert.True(project.HasUnsavedChanges); 422Assert.True(project.HasUnsavedChanges); 554Assert.True(project.HasUnsavedChanges); 575Assert.True(project.HasUnsavedChanges); 620Assert.True(project.HasUnsavedChanges); 1181Assert.True(project.HasUnsavedChanges); 1345Assert.True(project.HasUnsavedChanges); 1369Assert.True(project.HasUnsavedChanges); 1426Assert.True(project.HasUnsavedChanges);
Construction\ProjectExtensionsElement_Tests.cs (1)
89Assert.True(extensions.ContainingProject.HasUnsavedChanges);
Construction\ProjectImportGroupElement_Tests.cs (3)
337Assert.True(project.HasUnsavedChanges); 379Assert.True(project.HasUnsavedChanges); 396Assert.True(project.HasUnsavedChanges);
Construction\ProjectItemDefinitionElement_Tests.cs (1)
213Assert.True(project.HasUnsavedChanges);
Construction\ProjectItemDefinitionGroupElement_Tests.cs (2)
109Assert.True(project.HasUnsavedChanges); 126Assert.True(project.HasUnsavedChanges);
Construction\ProjectItemElement_Tests.cs (4)
1011Assert.False(project.HasUnsavedChanges); 1016Assert.True(project.HasUnsavedChanges); 1031Assert.False(project.HasUnsavedChanges); 1036Assert.True(project.HasUnsavedChanges);
Construction\ProjectItemGroupElement_tests.cs (2)
89Assert.True(project.HasUnsavedChanges); 106Assert.True(project.HasUnsavedChanges);
Construction\ProjectMetadataElement_Tests.cs (2)
224Assert.True(metadatum.ContainingProject.HasUnsavedChanges); 238Assert.False(metadatum.ContainingProject.HasUnsavedChanges);
Construction\ProjectOnErrorElement_Tests.cs (2)
267Assert.True(project.HasUnsavedChanges); 285Assert.True(project.HasUnsavedChanges);
Construction\ProjectOutputElement_Tests.cs (3)
217Assert.True(output.ContainingProject.HasUnsavedChanges); 231Assert.True(output.ContainingProject.HasUnsavedChanges); 258Assert.True(output.ContainingProject.HasUnsavedChanges);
Construction\ProjectPropertyElement_Tests.cs (6)
164Assert.True(property.ContainingProject.HasUnsavedChanges); 180Assert.False(property.ContainingProject.HasUnsavedChanges); 193Assert.True(property.ContainingProject.HasUnsavedChanges); 207Assert.False(property.ContainingProject.HasUnsavedChanges); 234Assert.True(property.ContainingProject.HasUnsavedChanges); 262Assert.True(property.ContainingProject.HasUnsavedChanges);
Construction\ProjectPropertyGroupElement_Tests.cs (2)
87Assert.True(project.HasUnsavedChanges); 104Assert.True(project.HasUnsavedChanges);
Construction\ProjectRootElement_Tests.cs (5)
112Assert.True(project.HasUnsavedChanges); // it is indeed unsaved 125Assert.True(project.HasUnsavedChanges); 138Assert.True(project.HasUnsavedChanges); 151Assert.True(project.HasUnsavedChanges); 1867Assert.True(projectElement.HasUnsavedChanges);
Construction\ProjectTargetElement_Tests.cs (10)
64Assert.True(project.HasUnsavedChanges); 226Assert.True(project.HasUnsavedChanges); 242Assert.True(project.HasUnsavedChanges); 258Assert.True(project.HasUnsavedChanges); 274Assert.True(project.HasUnsavedChanges); 290Assert.True(project.HasUnsavedChanges); 306Assert.True(project.HasUnsavedChanges); 323Assert.True(project.HasUnsavedChanges); 330Assert.True(project.HasUnsavedChanges); 337Assert.True(project.HasUnsavedChanges);
Construction\ProjectTaskElement_Tests.cs (5)
163Assert.True(task.ContainingProject.HasUnsavedChanges); 231Assert.True(task.ContainingProject.HasUnsavedChanges); 247Assert.True(task.ContainingProject.HasUnsavedChanges); 279Assert.True(project.HasUnsavedChanges); 294Assert.True(project.HasUnsavedChanges);
Construction\ProjectUsingTaskElement_Tests.cs (5)
254Assert.True(usingTask.ContainingProject.HasUnsavedChanges); 268Assert.True(usingTask.ContainingProject.HasUnsavedChanges); 309Assert.True(usingTask.ContainingProject.HasUnsavedChanges); 324Assert.True(usingTask.ContainingProject.HasUnsavedChanges); 339Assert.True(usingTask.ContainingProject.HasUnsavedChanges);
Construction\UsingTaskBodyElement_Tests.cs (2)
82Assert.True(body.ContainingProject.HasUnsavedChanges); 96Assert.True(body.ContainingProject.HasUnsavedChanges);
Construction\UsingTaskParameterElement_Tests.cs (9)
107Assert.True(parameter.ContainingProject.HasUnsavedChanges); 121Assert.True(parameter.ContainingProject.HasUnsavedChanges); 135Assert.True(parameter.ContainingProject.HasUnsavedChanges); 149Assert.True(parameter.ContainingProject.HasUnsavedChanges); 163Assert.True(parameter.ContainingProject.HasUnsavedChanges); 177Assert.True(parameter.ContainingProject.HasUnsavedChanges); 191Assert.True(parameter.ContainingProject.HasUnsavedChanges); 205Assert.True(parameter.ContainingProject.HasUnsavedChanges); 219Assert.True(parameter.ContainingProject.HasUnsavedChanges);
Definition\Project_Tests.cs (7)
1458import.HasUnsavedChanges.ShouldBeFalse(); 1523import.HasUnsavedChanges.ShouldBeFalse(); 1534import.HasUnsavedChanges.ShouldBeTrue(); 1607projectRootElement.HasUnsavedChanges.ShouldBeFalse(); 1616projectRootElement.HasUnsavedChanges.ShouldBeTrue(); 2185project.Xml.HasUnsavedChanges.ShouldBeTrue(); // Not dirty for saving 2202project.Xml.HasUnsavedChanges.ShouldBeFalse(); // Not dirty for saving
ObjectModelRemoting\Helpers\ViewValidation.construction.cs (2)
533Assert.Equal(realXml.HasUnsavedChanges, viewXml.HasUnsavedChanges);
ObjectModelRemoting\LinkedSpecialCasesScenarios.cs (10)
97Assert.True(xmlPair.View.HasUnsavedChanges); 99Assert.False(xmlPair.View.HasUnsavedChanges); 111Assert.False(sourceProject.HasUnsavedChanges); 127Assert.True(xmlPair.View.HasUnsavedChanges); 128Assert.True(xmlPair.Real.HasUnsavedChanges); 151Assert.True(xmlPair.View.HasUnsavedChanges); 153Assert.False(xmlPair.View.HasUnsavedChanges); 180Assert.True(xmlPair.View.HasUnsavedChanges); 181Assert.False(externalSource && sourceProject.HasUnsavedChanges); 200Assert.False(externalSource && sourceProject.HasUnsavedChanges);
ObjectModelRemoting\RemoteProjectsProviderMock\ConstructionLinkMocks\MockProjectRootElementLink.cs (1)
33public bool HasUnsavedChanges => this.ProjectXml.HasUnsavedChanges;
Microsoft.Build.UnitTests.Shared (1)
ObjectModelHelpers.cs (1)
1988Assert.False(project.HasUnsavedChanges);