summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Xaml.UnitTests
diff options
context:
space:
mode:
authorStephane Delcroix <stephane@delcroix.org>2016-10-12 09:11:29 +0200
committerGitHub <noreply@github.com>2016-10-12 09:11:29 +0200
commit0a9f7bbc5598906feb59bae714d5bbc6d37919e2 (patch)
tree282c665c2cd4b855c737d9f5bcac98897e43e53d /Xamarin.Forms.Xaml.UnitTests
parent46b57aaa0e9e902537c1cc8c99e4c7bd07c70657 (diff)
downloadxamarin-forms-0a9f7bbc5598906feb59bae714d5bbc6d37919e2.tar.gz
xamarin-forms-0a9f7bbc5598906feb59bae714d5bbc6d37919e2.tar.bz2
xamarin-forms-0a9f7bbc5598906feb59bae714d5bbc6d37919e2.zip
[XamlG] Fully qualify method names (#417)
Diffstat (limited to 'Xamarin.Forms.Xaml.UnitTests')
-rw-r--r--Xamarin.Forms.Xaml.UnitTests/Issues/Bz43301.xaml5
-rw-r--r--Xamarin.Forms.Xaml.UnitTests/Issues/Bz43301.xaml.cs31
-rw-r--r--Xamarin.Forms.Xaml.UnitTests/Xamarin.Forms.Xaml.UnitTests.csproj10
3 files changed, 44 insertions, 2 deletions
diff --git a/Xamarin.Forms.Xaml.UnitTests/Issues/Bz43301.xaml b/Xamarin.Forms.Xaml.UnitTests/Issues/Bz43301.xaml
new file mode 100644
index 00000000..283ec9b9
--- /dev/null
+++ b/Xamarin.Forms.Xaml.UnitTests/Issues/Bz43301.xaml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ContentPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" x:Class="Foo.Xamarin.Bar.Bz43301">
+ <ContentPage.Content>
+ </ContentPage.Content>
+</ContentPage>
diff --git a/Xamarin.Forms.Xaml.UnitTests/Issues/Bz43301.xaml.cs b/Xamarin.Forms.Xaml.UnitTests/Issues/Bz43301.xaml.cs
new file mode 100644
index 00000000..e57f42d1
--- /dev/null
+++ b/Xamarin.Forms.Xaml.UnitTests/Issues/Bz43301.xaml.cs
@@ -0,0 +1,31 @@
+´╗┐using Xamarin.Forms;
+using NUnit.Framework;
+
+namespace Foo.Xamarin.Bar
+{
+ public partial class Bz43301 : ContentPage
+ {
+ public Bz43301()
+ {
+ InitializeComponent();
+ }
+
+ public Bz43301(bool useCompiledXaml)
+ {
+ //this stub will be replaced at compile time
+ }
+
+ [TestFixture]
+ class Tests
+ {
+ [TestCase(true)]
+ [TestCase(false)]
+ //No need for any actual [Test]. If this compiles, the bug is fixed.
+ public void DoesCompile(bool useCompiledXaml)
+ {
+ var layout = new Bz43301(useCompiledXaml);
+ Assert.Pass();
+ }
+ }
+ }
+} \ No newline at end of file
diff --git a/Xamarin.Forms.Xaml.UnitTests/Xamarin.Forms.Xaml.UnitTests.csproj b/Xamarin.Forms.Xaml.UnitTests/Xamarin.Forms.Xaml.UnitTests.csproj
index dc7f7ea1..a5ebbd92 100644
--- a/Xamarin.Forms.Xaml.UnitTests/Xamarin.Forms.Xaml.UnitTests.csproj
+++ b/Xamarin.Forms.Xaml.UnitTests/Xamarin.Forms.Xaml.UnitTests.csproj
@@ -368,9 +368,12 @@
<Compile Include="XStaticException.xaml.cs">
<DependentUpon>XStaticException.xaml</DependentUpon>
</Compile>
- <Compile Include="CompiledTypeConverter.xaml.cs" >
+ <Compile Include="CompiledTypeConverter.xaml.cs">
<DependentUpon>CompiledTypeConverter.xaml</DependentUpon>
</Compile>
+ <Compile Include="Issues\Bz43301.xaml.cs">
+ <DependentUpon>Bz43301.xaml</DependentUpon>
+ </Compile>
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<Import Project="..\.nuspec\Xamarin.Forms.Debug.targets" />
@@ -656,7 +659,10 @@
<EmbeddedResource Include="XStaticException.xaml">
<Generator>MSBuild:UpdateDesignTimeXaml</Generator>
</EmbeddedResource>
- <EmbeddedResource Include="CompiledTypeConverter.xaml" >
+ <EmbeddedResource Include="CompiledTypeConverter.xaml">
+ <Generator>MSBuild:UpdateDesignTimeXaml</Generator>
+ </EmbeddedResource>
+ <EmbeddedResource Include="Issues\Bz43301.xaml">
<Generator>MSBuild:UpdateDesignTimeXaml</Generator>
</EmbeddedResource>
</ItemGroup>