/CodePro Analytix Evaluation/src/com/instantiations/example/miscellaneous/MappingCode.java
 
Code Coverage Summary 100.0% coverage
Executable Lines 6
Line Coverage 100.0%
Block Coverage 100.0%
Instruction Coverage 100.0%
    
Legend
Line is fully covered
Line is partially covered
Line is not covered
Source
1 package com.instantiations.example.miscellaneous;
2
3 import java.util.*;
4
5 /**
6  * The class <code>MappingCode</code> demonstrates how the test case generator
7  * can use static analysis to create good values of even complex objects such
8  * as a {@link Map}.
9  * @author Brad Billings
10  */
11 public class MappingCode
12 {
13     public int testStrings(Map map)
14     {
15         if (map == null) {
16             return 0;
17         }
18         if ("value".equals(map.get("key"))) {
19             return 1;
20         }
21         return 2;
22     }
23 }
Powered by CodePro AnalytiX