From f23e3c2e9e3c7ad208c723a62f94ab2643a4a5af Mon Sep 17 00:00:00 2001
From: Koen Wermer <koenwermer@gmail.com>
Date: Sun, 5 Mar 2017 01:42:29 +0100
Subject: [PATCH] ran the daikon tests for basesecantsolver except for the
 soSolve function

---
 Daikon.hs                   |  4 ++--
 Results/Daikon results.txt  |  6 ++++++
 Tests/BaseSecantSolver.java | 26 +++++++++++++++++++++-----
 3 files changed, 29 insertions(+), 7 deletions(-)

diff --git a/Daikon.hs b/Daikon.hs
index a313512..8c26d31 100644
--- a/Daikon.hs
+++ b/Daikon.hs
@@ -7,7 +7,7 @@ import System.Directory
 import Data.List
 
 testNr :: Int
-testNr = 2
+testNr = 3
 
 source, pathDir, packageDir, methodName :: String
 source = case testNr of
@@ -21,7 +21,7 @@ pathDir = case testNr of
 methodName = case testNr of
                 1 -> "hasNext"
                 2 -> "value"
-                3 -> "doSolve"
+                3 -> "verifyBracketing"
 
 packageDir = map (\c -> if c == '/' then '.' else c) pathDir
 
diff --git a/Results/Daikon results.txt b/Results/Daikon results.txt
index 91f40b6..1bddbc3 100644
--- a/Results/Daikon results.txt	
+++ b/Results/Daikon results.txt	
@@ -8,4 +8,10 @@ GradientFunction:
 5 mutations with error found: 2, 9, 13, 14, 22
 4 mutations with error found not detected by wlp: 9, 13, 14, 22
 0 mutations with unterminated calls
+0 mutations stuck in a loop
+
+BaseSecantSolver (doSolve not checked yet):
+0 mutations with error found: 
+0 mutations with error found not detected by wlp: 
+0 mutations with unterminated calls
 0 mutations stuck in a loop
\ No newline at end of file
diff --git a/Tests/BaseSecantSolver.java b/Tests/BaseSecantSolver.java
index 48d835c..2bcf1dc 100644
--- a/Tests/BaseSecantSolver.java
+++ b/Tests/BaseSecantSolver.java
@@ -52,7 +52,7 @@ import org.apache.commons.math3.util.FastMath;
  *
  * @since 3.0
  */
-public abstract class BaseSecantSolver
+public class BaseSecantSolver
     extends AbstractUnivariateSolver
     implements BracketedUnivariateSolver<UnivariateFunction> {
 
@@ -71,7 +71,7 @@ public abstract class BaseSecantSolver
      * @param absoluteAccuracy Absolute accuracy.
      * @param method <em>Secant</em>-based root-finding method to use.
      */
-    protected BaseSecantSolver(final double absoluteAccuracy, final Method method1) {
+    public BaseSecantSolver(final double absoluteAccuracy, final Method method1) {
         super(absoluteAccuracy);
         this.allowed = AllowedSolution.ANY_SIDE;
         this.method = method1;
@@ -84,7 +84,7 @@ public abstract class BaseSecantSolver
      * @param absoluteAccuracy Absolute accuracy.
      * @param method <em>Secant</em>-based root-finding method to use.
      */
-    protected BaseSecantSolver(final double relativeAccuracy,
+    public BaseSecantSolver(final double relativeAccuracy,
                                final double absoluteAccuracy1,
                                final Method method2) {
         super(relativeAccuracy, absoluteAccuracy1);
@@ -100,7 +100,7 @@ public abstract class BaseSecantSolver
      * @param functionValueAccuracy Maximum function value error.
      * @param method <em>Secant</em>-based root-finding method to use
      */
-    protected BaseSecantSolver(final double relativeAccuracy2,
+    public BaseSecantSolver(final double relativeAccuracy2,
                                final double absoluteAccuracy2,
                                final double functionValueAccuracy,
                                final Method method3) {
@@ -109,7 +109,7 @@ public abstract class BaseSecantSolver
         this.method = method3;
     }
 
-    protected final double doSolve()
+    public final double doSolve()
         throws ConvergenceException {
         // Get initial solution
         double x0 = getMin();
@@ -302,4 +302,20 @@ public abstract class BaseSecantSolver
         }
     }
     
+    
+    
+    
+    
+    public double solve(int maxEval, UnivariateFunction f, double min, double max, double startValue,
+                 AllowedSolution allowedSolution)
+                 {
+                     return 0;
+                 }
+    
+    
+    public double solve(int maxEval, UnivariateFunction f, double min, double max,
+                 AllowedSolution allowedSolution)
+                 {
+                     return 0;
+                 }
 }
-- 
GitLab