Clover Coverage Report
Coverage timestamp: Fri May 24 2013 13:47:27 UTC
../../../../../../img/srcFileCovDistChart5.png 87% of files have more coverage
14   69   5   7
0   31   0.36   2
2     2.5  
1    
 
  TestFormulaCheckerImpl       Line # 30 14 5 43.8% 0.4375
 
  (8)
 
1    /* This file is part of the project "Hilbert II" - http://www.qedeq.org
2    *
3    * Copyright 2000-2013, Michael Meyling <mime@qedeq.org>.
4    *
5    * "Hilbert II" is free software; you can redistribute
6    * it and/or modify it under the terms of the GNU General Public
7    * License as published by the Free Software Foundation; either
8    * version 2 of the License, or (at your option) any later version.
9    *
10    * This program is distributed in the hope that it will be useful,
11    * but WITHOUT ANY WARRANTY; without even the implied warranty of
12    * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13    * GNU General Public License for more details.
14    */
15   
16    package org.qedeq.kernel.bo.logic.wf;
17   
18    import java.lang.reflect.InvocationTargetException;
19   
20    import org.qedeq.base.test.DynamicGetter;
21    import org.qedeq.kernel.bo.common.KernelServices;
22    import org.qedeq.kernel.se.base.module.Qedeq;
23   
24   
25    /**
26    * For checking the context.
27    *
28    * @author Michael Meyling
29    */
 
30    public class TestFormulaCheckerImpl extends FormulaCheckerImpl {
31   
32    private KernelServices services;
33   
34    /**
35    * Constructor.
36    *
37    */
 
38  251 toggle public TestFormulaCheckerImpl(final KernelServices services) {
39  251 this.services = services;
40    }
41   
42    /**
43    * Set location information where are we within the original module.
44    *
45    * @param locationWithinModule Location within module.
46    */
 
47  41513 toggle protected void setLocationWithinModule(final String locationWithinModule) {
48  41513 final Qedeq qedeq = services.getQedeqBo(getCurrentContext()
49    .getModuleLocation()).getQedeq();
50  41513 try {
51    // System.out.println(locationWithinModule);
52  41513 DynamicGetter.get(qedeq, getCurrentContext().getLocationWithinModule());
53    } catch (IllegalAccessException e) {
54  0 System.out.println("checking " + locationWithinModule);
55  0 e.printStackTrace(System.out);
56  0 throw new RuntimeException(e);
57    } catch (InvocationTargetException e) {
58  0 System.out.println("checking " + locationWithinModule);
59  0 e.printStackTrace(System.out);
60  0 throw new RuntimeException(e);
61    } catch (RuntimeException e) {
62  0 System.out.println("checking " + locationWithinModule);
63  0 e.printStackTrace(System.out);
64  0 throw e;
65    }
66  41513 getCurrentContext().setLocationWithinModule(locationWithinModule);
67    }
68   
69    }