Exemple #1
0
		public void TestCopyCustomMetadataTo2 ()
		{
			BuildItem item = new BuildItem ("name", "include");
			item.SetMetadata ("name", "value");
			
			item.CopyCustomMetadataTo (null);
		}
Exemple #2
0
		public void TestCopyCustomMetadataTo1 ()
		{
			BuildItem source, destination;
			string itemName1 = "a";
			string itemName2 = "b";
			string itemInclude = "a;b;c";
			string metadataName = "name";
			string metadataValue = "value";

			source = new BuildItem (itemName1, itemInclude);
			destination = new BuildItem (itemName2, itemInclude);

			source.SetMetadata (metadataName, metadataValue);

			source.CopyCustomMetadataTo (destination);

			Assert.AreEqual (metadataValue, destination.GetMetadata (metadataName), "A1");
			Assert.AreEqual (metadataValue, destination.GetEvaluatedMetadata (metadataName), "A2");
		}