Skip to content

Commit 3400675

Browse files
committed
test: fix tests
1 parent e2a5a71 commit 3400675

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

test/Thinktecture.Runtime.Extensions.SourceGenerator.Tests/Extensions/FieldSymbolExtensionsTests/GetFieldLocation.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ public enum MyEnum
408408
Second = 2
409409
}
410410
";
411-
var compilation = CreateCompilation(src);
411+
var compilation = CreateCompilation(src, [typeof(System.ComponentModel.DescriptionAttribute).Assembly.Location]);
412412
var type = GetTypeSymbol(compilation, "Test.MyEnum");
413413
var firstMember = type.GetMembers("First").OfType<IFieldSymbol>().Single();
414414

@@ -775,7 +775,7 @@ public class MyClass
775775
private int _attributedField;
776776
}
777777
";
778-
var compilation = CreateCompilation(src);
778+
var compilation = CreateCompilation(src, [typeof(System.ComponentModel.DescriptionAttribute).Assembly.Location]);
779779
var type = GetTypeSymbol(compilation, "Test.MyClass");
780780
var field = type.GetMembers("_attributedField").OfType<IFieldSymbol>().Single();
781781

test/Thinktecture.Runtime.Extensions.SourceGenerator.Tests/Extensions/PropertySymbolExtensionsTests/GetPropertyLocation.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1137,7 +1137,7 @@ public class MyClass
11371137
public int AttributedProperty { get; set; }
11381138
}
11391139
";
1140-
var compilation = CreateCompilation(src);
1140+
var compilation = CreateCompilation(src, [typeof(System.ComponentModel.DescriptionAttribute).Assembly.Location]);
11411141
var type = GetTypeSymbol(compilation, "Test.MyClass");
11421142
var property = type.GetMembers("AttributedProperty").OfType<IPropertySymbol>().Single();
11431143

0 commit comments

Comments
 (0)