Skip to content
This repository was archived by the owner on Nov 19, 2020. It is now read-only.

Conversation

ar7z1
Copy link
Contributor

@ar7z1 ar7z1 commented Jul 13, 2017

In this PR I fixed #706.

@@ -60,7 +60,7 @@ public void Write(DecisionTree tree, string className)
writer.WriteLine("namespace DecisionTrees");
writer.WriteLine("{");
writer.WriteLine(" using System.CodeDom.Compiler;");
writer.WriteLine(" using System.Collections.Generic;");
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 was unused using.

var csc = new CSharpCodeProvider();
var parameters = new CompilerParameters(new[] { "System.dll", "mscorlib.dll" }) {GenerateInMemory = true};

var compilerResult = csc.CompileAssemblyFromSource(parameters, tree.ToCode("AccordDecisionTree"));
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This test only checks that generated code compiles.

@ar7z1
Copy link
Contributor Author

ar7z1 commented Jul 13, 2017

@cesarsouza Do you need some help to fix CI build for development branch?

@cesarsouza
Copy link
Member

Hi @ar7z1,

Thanks a lot for the pull request! - and regarding the CI build, indeed I would certainly welcome some help, as I will not have much time to work on it in the next few days.

It seems that one of the unit tests are getting stuck after I updated Travis to run the unit tests using NUnit 3 instead of NUnit 2, but I cannot know exactly which test is causing this. I am sure there must be some parameter I could pass to Travis, or some file I could analyze afterwards, but I haven't gotten the chance to investigate it yet.

Regards,
Cesar

@cesarsouza cesarsouza merged commit 8af4b78 into accord-net:development Jul 15, 2017
@cesarsouza
Copy link
Member

cesarsouza commented Jul 15, 2017

Again, thanks a lot for the pull request.

Regarding the failing tests, I think I have been able to solve the mystery failing test happening before. Now the problem is some issue with the Accord.Tests.Vision project, as NUnit is not being able to load tests from it properly, for some reason.

Regards,
Cesar

cesarsouza added a commit that referenced this pull request Jul 16, 2017
…) unit test when running in .NET Standardard 2.0 (at least for now).

 - Updates GH-707
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DecisionTree.ToCode() returns code that does not compile
2 participants