shekharpro / mb-unit

Automatically exported from code.google.com/p/mb-unit
0 stars 0 forks source link

Exceptions in R# 4.5 test runner #462

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Running/exploring tests with R# 4.5 (4.5.1242.5) and Gallio (any version
above 3.07.136, currently 3.07.150).
2. A continual flood of ArgumentNullException at the
StaticParameterWrapper.ctor get reported by R#; test runner doesn't work.

What is the expected output? What do you see instead?

What version of the product are you using? On what operating system?

Please provide any additional information below.

The stacktrace in the attachment. May be related to Issue 449.

Original issue reported on code.google.com by max.kost...@gmail.com on 30 May 2009 at 8:41

Attachments:

GoogleCodeExporter commented 8 years ago
Is there a particular snippet of code on which this happens?

Original comment by jeff.br...@gmail.com on 30 May 2009 at 8:57

GoogleCodeExporter commented 8 years ago
Yes, I've commented out all code in the fixture until the errors stopped and 
found
that any anonymous function declaration with arguments (in both delegate and 
lambda
syntax) leads to this exception:

[Test]
public void Delegate_with_args_throws()
{
    Action<int> throws = delegate(int i) { };
}

[Test]
public void Delegate_with_args_lambda_syntax_throws()
{
    // Action a = () => { }; // - doesn't throw
    // Func<int> f = () => 0; // - doesn't throw
    Action<int> throws = i => { };
}

Original comment by max.kost...@gmail.com on 31 May 2009 at 6:04

GoogleCodeExporter commented 8 years ago
Ah ha!  Thanks for figuring this out.

Ok, I remember looking at the parameter creation code and wondering whether 
under any
circumstances the parameters owner might not be able to be resolved as a 
declared
method.  Now I know...

This bug will also exist in v3.0.6.

Fortunately it's pretty easy to fix.

Original comment by jeff.br...@gmail.com on 31 May 2009 at 6:27

GoogleCodeExporter commented 8 years ago
Fixed in v3.0.7 build 159.  Will also appear in v3.0.6 Update 3.

Original comment by jeff.br...@gmail.com on 5 Jun 2009 at 6:32