Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Köplinger <alex.koeplinger@outlook.com>2019-03-27 13:39:22 +0300
committerAlexander Köplinger <alex.koeplinger@outlook.com>2019-03-27 13:39:22 +0300
commit1bc213fac159282ffe812a209bd5db84d472da7d (patch)
treea36f911123d447e1ea1645df8334aeb7c78db102 /mcs/class/System.XML
parent5602acf3997f7b816659f7390b7df451eeb882cd (diff)
[System.Xml] Don't hardcode nunit-lite-console in GeneratedCodeAttribute
Instead determine it at runtime.
Diffstat (limited to 'mcs/class/System.XML')
-rw-r--r--mcs/class/System.XML/Test/System.Xml.Serialization/XmlCodeExporterTests.cs5
1 files changed, 3 insertions, 2 deletions
diff --git a/mcs/class/System.XML/Test/System.Xml.Serialization/XmlCodeExporterTests.cs b/mcs/class/System.XML/Test/System.Xml.Serialization/XmlCodeExporterTests.cs
index d08b16b98c8..d6bd6a44ad1 100644
--- a/mcs/class/System.XML/Test/System.Xml.Serialization/XmlCodeExporterTests.cs
+++ b/mcs/class/System.XML/Test/System.Xml.Serialization/XmlCodeExporterTests.cs
@@ -45,10 +45,11 @@ namespace MonoTests.System.XmlSerialization
ICodeGenerator generator = provider.CreateGenerator ();
generator.GenerateCodeFromNamespace (codeNamespace, sw, new CodeGeneratorOptions ());
+ var currentAssembly = Assembly.GetEntryAssembly ().GetName ();
Assert.AreEqual (string.Format(CultureInfo.InvariantCulture,
"{0}{0}" +
"/// <remarks/>{0}" +
- "[System.CodeDom.Compiler.GeneratedCodeAttribute(\"nunit-lite-console\", \"0.0.0.0\")]{0}" +
+ "[System.CodeDom.Compiler.GeneratedCodeAttribute(\"{1}\", \"{2}\")]{0}" +
"[System.SerializableAttribute()]{0}" +
"[System.Diagnostics.DebuggerStepThroughAttribute()]{0}" +
"[System.ComponentModel.DesignerCategoryAttribute(\"code\")]{0}" +
@@ -66,7 +67,7 @@ namespace MonoTests.System.XmlSerialization
" this.namesField = value;{0}" +
" }}{0}" +
" }}{0}" +
- "}}{0}", Environment.NewLine), sw.ToString (), "#2");
+ "}}{0}", Environment.NewLine, currentAssembly.Name, currentAssembly.Version), sw.ToString (), "#2");
codeNamespace = ExportCode (typeof (ArrayClass[]));