Skip to content
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

Miscellaneous test fixes #482

Closed
wants to merge 5 commits into from
Closed

Miscellaneous test fixes #482

wants to merge 5 commits into from

Conversation

latkin
Copy link
Contributor

@latkin latkin commented Jun 2, 2015

Various fixes to address bitrot in the tests - uncovered these as I am getting our internal test infrastructure running again.

  • Older NUnit used internally compares collections differently
    • Has trouble with nested collections
    • Enforces that empty collections have the same type (newer NUnit is lax about this)
  • Add NoMT test tag to various new tests that don't support mixed .NET version testing (i.e. .NET 2/4 multitargeting)
  • Make sure all IDE bits build with correct versions of VS SDK dependencies
    • IDE unit tests were all failing for me with latest VS RC installed
  • Various small tweaks to account for versioning and file paths used by VS

Assert.AreEqual([| [|1..4|]; [|5..8|] |], Array.chunkBySize 4 [|1..8|])
Assert.AreEqual([| [|1..4|]; [|5..8|]; [|9..10|] |], Array.chunkBySize 4 [|1..10|])
Assert.AreEqual([| [|1|]; [|2|]; [|3|]; [|4|] |], Array.chunkBySize 1 [|1..4|])
Assert.IsTrue([| [|1..4|]; [|5..8|] |] = Array.chunkBySize 4 [|1..8|])
Copy link
Contributor

Choose a reason for hiding this comment

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

are you sure we want this? The reporting will be worse if something breaks.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's not perfect, no. Failures will still have a stack pointing to the line that failed, though, so it's not too bad. And FWIW this is the pattern used for most of the tests already (due to the same reason, that older NUnit has broken AreEqual for complicated collections).

Copy link
Contributor

Choose a reason for hiding this comment

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

rewriting tests in such a way because of an old test framework dependency, feels really like a bad idea.

@latkin latkin closed this in 275b832 Jun 3, 2015
@latkin latkin added the fixed label Jun 3, 2015
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.

None yet

3 participants