-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ba980b0
commit 5f6a01e
Showing
2 changed files
with
53 additions
and
0 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
...u.Test/Factory/FactoryAttributeTests/FactoryConstructorPreferredOverPrimaryConstructor.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
using Moyou.Aspects.Factory; | ||
|
||
namespace Moyou.CompileTimeTest.Factory.FactoryAttributeTests; | ||
|
||
[Factory] | ||
[FactoryMember(TargetType = typeof(ClassE))] | ||
public class FactoryE | ||
{ | ||
|
||
} | ||
|
||
public interface InterfaceE | ||
{ | ||
|
||
} | ||
|
||
public class ClassE : InterfaceE | ||
{ | ||
public ClassE() | ||
{ | ||
|
||
} | ||
|
||
[FactoryConstructor] | ||
public ClassE(int foobar, string barbaz, object bobo) | ||
{ | ||
|
||
} | ||
} |
24 changes: 24 additions & 0 deletions
24
...Test/Factory/FactoryAttributeTests/FactoryConstructorPreferredOverPrimaryConstructor.t.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
using Moyou.Aspects.Factory; | ||
namespace Moyou.CompileTimeTest.Factory.FactoryAttributeTests; | ||
[Factory] | ||
[FactoryMember(TargetType = typeof(ClassE))] | ||
public class FactoryE | ||
{ | ||
public global::Moyou.CompileTimeTest.Factory.FactoryAttributeTests.InterfaceE CreatenterfaceE(global::System.Int32 foobar, global::System.String barbaz, global::System.Object bobo) | ||
{ | ||
return new global::Moyou.CompileTimeTest.Factory.FactoryAttributeTests.ClassE((global::System.Int32)foobar, (global::System.String)barbaz, bobo); | ||
} | ||
} | ||
public interface InterfaceE | ||
{ | ||
} | ||
public class ClassE : InterfaceE | ||
{ | ||
public ClassE() | ||
{ | ||
} | ||
[FactoryConstructor] | ||
public ClassE(int foobar, string barbaz, object bobo) | ||
{ | ||
} | ||
} |