Skip to content

Conversation

@jayaranigarg
Copy link
Member

@jayaranigarg jayaranigarg commented Jun 27, 2018

@jayaranigarg jayaranigarg changed the title Adding appropriate error message Adding appropriate error message for TestMethods expecting parameters but parameters not provided Jun 27, 2018
<data name="TestAssembly_AssemblyDiscoveryFailure" xml:space="preserve">
<value>Failed to discover tests from assembly {0}. Reason:{1}</value>
</data>
<data name="UTA_TestMethodExpectedParameters" xml:space="preserve">
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Xlf file changes?
@pvlakshm Please review the string

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

{
if (methodInfo.GetParameters() != null && parameters == null)
{
string errorMessage = string.Format(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ResourceManager takes care of culture, do we need this formating?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Validated on a DEU machine. ResourceManager working expectedly. 👍

/// </param>
internal static void InvokeAsSynchronousTask(this MethodInfo methodInfo, object classInstance, params object[] parameters)
{
if (methodInfo.GetParameters() != null && parameters == null)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please explain the parameters null check

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added comments.

@jayaranigarg
Copy link
Member Author

@dotnet-bot Test Windows / Debug Build please

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants