检索规则说明:AND代表“并且”;OR代表“或者”;NOT代表“不包含”;(注意必须大写,运算符两边需空一格)
检 索 范 例 :范例一: (K=图书馆学 OR K=情报学) AND A=范并思 范例二:J=计算机应用与软件 AND (U=C++ OR U=Basic) NOT M=Visual
作 者:冯俊池 赵颖 连尧 尹党辉 安丰亮 Feng Junchi;Zhao Ying;Lian Yao;Yin Danghui;An Fengliang(Institute of Logistic Science and Technology,Beijing 100071,China)
机构地区:[1]后勤科学与技术研究所
出 处:《计算机测量与控制》2018年第4期70-73,共4页Computer Measurement &Control
摘 要:针对Java单元测试自动化程度和测试效率较低的问题,对基于Java程序的基本路径测试方法进行研究,提出了基于Java代码的基本路径生成方法和程序插桩方法,给出了插桩节点和控制流图节点的定义;首先,通过对Java源代码进行分析,构建程序的控制流图,进而对控制流图进行遍历生成基本路径集合;然后,对被测程序进行插桩,以获取程序的执行路径,插桩过程中保持节点和基本路径中的节点一致,使得插桩后的被测程序执行时得到的路径能够和基本路径集合进行自动化比对;最后,通过以测试数据为输入执行被测程序,对执行路径和基本路径进行比较,判断测试数据集对基本路径的覆盖度;通过实验,验证了所提出方法的有效性。The level of Java unit testing automation is low,and so is the testing efficiency.The basis path testing method based on Java program is studied.The basic path generation method based on Java source code and program instrumentation method is provided.The definition of instrumentation node and control flow graph node is given.Firstly,the control flow graph of program under test is built based on the analysis of Java source code,and then the control flow graph is traversed to generate the basis path set.Secondly,the program under test is instrumented to obtain the program execution path.The instrumentation node is consistent with the node of basis path,so the path obtained during execution can be compared with the basic path set automatically.Lastly,run the program under test with the test data as input,and compare the execution path with basis path to compute the basis path coverage of test data set.The effectiveness of the proposed method is verified by experiments.
分 类 号:TP311.5[自动化与计算机技术—计算机软件与理论]
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在链接到云南高校图书馆文献保障联盟下载...
云南高校图书馆联盟文献共享服务平台 版权所有©
您的IP:216.73.216.49