@@ -56,22 +56,6 @@ await Assert.ThrowsAnyAsync<Exception>(async () =>
56
56
} ) ;
57
57
}
58
58
59
- /* TODO figoure out how to associate the right output with the right classes
60
- [Theory]
61
- [InlineData("fred", "george", false, "fred.Equals(george)")]
62
- [InlineData("fred", "george", true, "!fred.Equals(george)")]
63
- [InlineData("fred", "george", false, "fred == george")]
64
- [InlineData("fred", "george", true, "fred != george")]
65
- public virtual void TestGenerateEqualsSnippet(string f1, string f2, bool negate, string expected)
66
- {
67
- var thing = Thing;
68
- var a1 = new Accessor(f1);
69
- var a2 = new Accessor(f2);
70
- var foo = thing.GenerateEqualsSnippet(a1, a2, negate);
71
- Assert.Equal(expected, foo);
72
- }
73
- */
74
-
75
59
public static TheoryData < string , string [ ] > CommentData => new ( )
76
60
{
77
61
{ null , Array . Empty < string > ( ) } ,
@@ -92,20 +76,6 @@ private T ThingWithComments(string commentString)
92
76
return thing ;
93
77
}
94
78
95
- private T ThingWithInterfaceComments ( string commentString , bool getter )
96
- {
97
- var thing = Thing ;
98
- if ( commentString is null ) return thing ;
99
-
100
- var comments = ( thing . Comments ??= new ( ) ) ;
101
- if ( getter )
102
- ( comments . GetterInterface ??= new ( null ! ) ) . Summary . AppendLine ( commentString ) ;
103
- else
104
- ( comments . SetterInterface ??= new ( null ! ) ) . Summary . AppendLine ( commentString ) ;
105
-
106
- return thing ;
107
- }
108
-
109
79
[ Theory ]
110
80
[ MemberData ( nameof ( CommentData ) ) ]
111
81
public async Task TestClassComments ( string commentString , string [ ] expected )
@@ -117,24 +87,4 @@ public async Task TestClassComments(string commentString, string[] expected)
117
87
118
88
Assert . Equal ( expected , sb . Where ( x => x . StartsWith ( "//" ) ) . ToArray ( ) ) ;
119
89
}
120
-
121
- public static TheoryData < bool > InterfaceOptionsData => new ( )
122
- {
123
- true ,
124
- false ,
125
- } ;
126
-
127
- public static MatrixTheoryData < string , string [ ] , bool > InterfaceCommentsData => new ( CommentData , InterfaceOptionsData ) ;
128
-
129
- [ Theory ]
130
- [ MemberData ( nameof ( InterfaceCommentsData ) ) ]
131
- public async Task TestInterfaceComments ( string commentString , string [ ] expected , bool getter )
132
- {
133
- var thing = ThingWithInterfaceComments ( commentString , getter ) ;
134
- var sb = new StructuredStringBuilder ( ) ;
135
-
136
- thing . GenerateForInterface ( sb , getter , false ) ;
137
-
138
- Assert . Equal ( expected , sb . Where ( x => x . StartsWith ( "//" ) ) . ToArray ( ) ) ;
139
- }
140
90
}
0 commit comments