Skip to content

Add Saddle Points test generator #463

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

Merged
merged 2 commits into from
Oct 5, 2017
Merged

Conversation

GKotfis
Copy link
Contributor

@GKotfis GKotfis commented Oct 5, 2017

This reference #421 issue.

  1. fix file name (missing 's') SaddlePointsTest
  2. add SaddlePoint test generator
  3. add multidimensional value formater
    What do you think about those changes - extension of ValueFormatter? :) This switch(val) in Format method gets bigger and bigger so maybe some refactoring needs to be done here (at least split to methods).

- add SaddlePoint test generator
- add multidimensional value formater
Copy link
Member

@ErikSchierboom ErikSchierboom left a comment

Choose a reason for hiding this comment

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

I agree that some refactoring is probably wise. Feel free to refactor some functionality into separate methods. The rest of it looks great.


canonicalDataCase.Properties["input"] = (canonicalDataCase.Properties["input"] as JArray).ToObject<int[,]>();

var array = (canonicalDataCase.Expected as Array);
Copy link
Member

Choose a reason for hiding this comment

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

You can lose the parentheses here

{
var input = new[,]
{
{ 9, 8, 7 },
Copy link
Member

Choose a reason for hiding this comment

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

The indentation is slight off (also in the other cases), I would expect the following:

var input = new[,]
{
    { 9, 8, 7 },
};

Copy link
Member

@ErikSchierboom ErikSchierboom left a comment

Choose a reason for hiding this comment

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

Let me know if you also want to do some refactoring. If you'd like to do that in a separate PR, that would be fine too.

@GKotfis
Copy link
Contributor Author

GKotfis commented Oct 5, 2017

I'll do refactoring in separate PR

@ErikSchierboom ErikSchierboom merged commit 4beeb96 into exercism:master Oct 5, 2017
@ErikSchierboom
Copy link
Member

Merged. Thanks again! 🎉

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