-
-
Notifications
You must be signed in to change notification settings - Fork 760
Enable first unit tests for InterfaceStubGenerator #1045
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
||
namespace Refit.Tests | ||
{ | ||
public static partial class CSharpSourceGeneratorVerifier<TSourceGenerator> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📝 This file would normally contain helpers for the most common cases, but we haven't identified those yet for source generators.
static readonly MetadataReference RefitAssembly = MetadataReference.CreateFromFile( | ||
typeof(GetAttribute).Assembly.Location, | ||
documentation: XmlDocumentationProvi 8000 der.CreateFromFile(Path.ChangeExtension(typeof(GetAttribute).Assembly.Location, ".xml"))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📝 This would be better if we could reference a NuGet package (where it would automatically detect the proper TFM to reference and include the corresponding dependencies), but that would restrict the tests to using a Refit build available on NuGet.
Looks like there are test failures here? |
Do you have a preference regarding #1045 (comment)? The options are:
|
Seems like 2 is better since we the CI feed would always be N-1 of the current, so there'd be no way to validate things before a commit? |
The tests are now updated. |
I'm seeing two test failures? |
I'm not seeing this locally, and the CI output isn't public so I'm not sure yet where the difference lies.
Yes, the test library uses NuGet to resolve package dependencies. |
The build/test output is public but ADO is being silly when you've already logged into a different ADO tenant. If you open the ADO link with an InPrivate window, you'll be able to see it. |
|
||
static InterfaceStubGeneratorTests() | ||
{ | ||
#if NET5_0_OR_GREATER |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤦♂️ Looks like this (specifically the _OR_GREATER
form) was added for the 5.0.2xx SDK, but the CI is using 5.0.1xx.
Good catch, we both have the 200 preview SDK's locally 😂 |
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
No description provided.