Clover Coverage Report
Coverage timestamp: Fri May 24 2013 13:47:27 UTC
20   103   15   1.54
4   54   0.75   13
13     1.15  
1    
 
  BasicKernelTest       Line # 25 20 15 83.8% 0.8378378
 
  (10)
 
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.common;
17   
18    import org.qedeq.kernel.bo.test.QedeqBoTestCase;
19   
20    /**
21    * Test class.
22    *
23    * @author Michael Meyling
24    */
 
25    public class BasicKernelTest extends QedeqBoTestCase {
26   
27    private BasicKernel kernel;
28   
29    /**
30    * Constructor.
31    *
32    */
 
33  0 toggle public BasicKernelTest() {
34  0 super();
35    }
36   
37    /**
38    * Constructor.
39    *
40    * @param name Test case name.
41    *
42    */
 
43  10 toggle public BasicKernelTest(final String name) {
44  10 super(name);
45    }
46   
 
47  10 toggle protected void setUp() throws Exception {
48  10 super.setUp();
49  10 kernel = new BasicKernel();
50    }
51   
 
52  1 toggle public void testGetBuildId() {
53  1 assertNotNull(kernel.getBuildId());
54    }
55   
 
56  1 toggle public void testGetKernelVersion() {
57  1 assertNotNull(kernel.getKernelVersion());
58    }
59   
 
60  1 toggle public void testGetDedicationVersion() {
61  1 assertNotNull(kernel.getDedication());
62    }
63   
 
64  1 toggle public void testGetDescriptiveKernelVersion() {
65  1 assertNotNull(kernel.getDescriptiveKernelVersion());
66    }
67   
 
68  1 toggle public void testGetKernelCodeName() {
69  1 assertNotNull(kernel.getKernelCodeName());
70    }
71   
 
72  1 toggle public void testGetKernelVersionDirectory() {
73  1 assertNotNull(kernel.getKernelVersionDirectory());
74    }
75   
 
76  1 toggle public void testIsRuleVersionSupported() {
77  1 assertTrue(kernel.isRuleVersionSupported("1.01.00"));
78  1 assertTrue(kernel.isRuleVersionSupported(kernel.getMaximalRuleVersion()));
79  1 assertFalse(kernel.isRuleVersionSupported("1.00.00"));
80    }
81   
 
82  1 toggle public void testGetMaximalRuleVersion() {
83  1 assertEquals("1.01.00", kernel.getMaximalRuleVersion());
84    }
85   
 
86  1 toggle public void testIsSetConnectionTimeOutSupported() {
87  1 if (System.getProperty("java.runtime.version").compareTo("1.5") <= 0) {
88  0 assertFalse(kernel.isSetConnectionTimeOutSupported());
89    } else {
90  1 assertTrue(kernel.isSetConnectionTimeOutSupported());
91    }
92    }
93   
 
94  1 toggle public void testIsSetReadTimeoutSupported() {
95  1 if (System.getProperty("java.runtime.version").compareTo("1.5") <= 0) {
96  0 assertFalse(kernel.isSetReadTimeoutSupported());
97    } else {
98  1 assertTrue(kernel.isSetReadTimeoutSupported());
99    }
100    }
101   
102   
103    }