Inferring Test Models from Kates Bug Reports using Multi-objective - - PowerPoint PPT Presentation

inferring test models from kate s bug reports using multi
SMART_READER_LITE
LIVE PREVIEW

Inferring Test Models from Kates Bug Reports using Multi-objective - - PowerPoint PPT Presentation

Inferring Test Models from Kates Bug Reports using Multi-objective Search Yuanyuan Zhang Mark Harman Yue Jia and Federica Sarro University College London SSBSE 2015 Challenge Track Paper Which page should we put more effort to proofread?


slide-1
SLIDE 1

Inferring Test Models from Kate’s Bug Reports using Multi-objective Search

Yuanyuan Zhang Mark Harman Yue Jia and Federica Sarro University College London SSBSE 2015 Challenge Track Paper

slide-2
SLIDE 2
slide-3
SLIDE 3
slide-4
SLIDE 4

Which page should we put more effort to proofread?

slide-5
SLIDE 5

Motivation

Up to 24% of post-release bug fixes of large software systems are incorrect and even introduce additional faults

slide-6
SLIDE 6

Input: an abstraction of the observed sequences

  • log files (contain a sequence of execution traces

function calls) <println, formatter, close, println> Output: an inferred model

  • a FSM (accepts more traces than the observed
  • nes and might not accept some of the observed

traces)

Event-based Model Inference

  • bug reports (written in the natural language)
slide-7
SLIDE 7

Event-based Model Inference

  • bug reports (written in the natural language)

Challenges

A description of a bug Steps to Reproduce Actual Results Expected Results Reproducible or not?

slide-8
SLIDE 8

Event-based Model Inference Challenges

  • a FSM (accepts more traces than the observed ones

and might not accept some of the observed traces)

the generalisation capability of a model

introduce infeasible behaviours exclude possible behaviours

  • ver-generalising

under-generalising

  • ver-approximation

under-approximation

slide-9
SLIDE 9

1 2 3 4

Model Inference Framework

Extraction Parsing Data Mining

Seach-Based Model Generation

slide-10
SLIDE 10

1

Model Inference Framework

Extraction

  • 1. Filter Bug Reports

filter terms: product; bug status; bug severity

  • I1. Extract All Valid Bug Report IDs
  • III. Crawl Bug Reports

BUG REPORT HTML HTML HTML

slide-11
SLIDE 11

2

Model Inference Framework

Parsing

  • 1. Filter Bug Reports

Description Steps to Reproduce Actual Results Expected Results Reproducible

slide-12
SLIDE 12

2

Model Inference Framework

Parsing

  • 1. Filter Bug Reports
  • I1. OUTPUT .str Files

HTML HTML HTML HTML HTML STR

slide-13
SLIDE 13

3

Model Inference Framework

Data Mining

  • 1. Preparing Training Corpus

All User Events VSM Model tf-idf Matrix Prepared Training Corpus pre-process transform project to n-dimensional latent semantic indexing space

slide-14
SLIDE 14

3

Model Inference Framework

Data Mining

Each User Event Prepared Training Corpus Event 1 0.99 similarity query cosine similarity

  • 1I. Clustering Similar User Events

The Updated User Events Trace Events cluster & intersection manual examine . . . Similar Events Similarity Event 2 0.75 Event 3 0.67

similarity threshold

slide-15
SLIDE 15

3

Model Inference Framework

Data Mining

  • 1I. Clustering Similar User Events
  • 1. Preparing Training Corpus
  • III. Mapping Trace Events

HTML HTML STR HTML HTML Trace events

slide-16
SLIDE 16
  • 1. Minimise over-approximation
  • 2. Minimise under-approximation
  • 3. Minimise the number of states in a model

Multi-objective Fitness Functions

Tonella, P., Marchetto, A., Nguyen, D.C., Jia, Y., Lakhotia, K., Harman, M.: Finding the Optimal Balance between Over and Under Approximation of Models Inferred from Execution Logs. In: Proceedings of IEEE 5th International Con- ference on Software Testing, Verification and Validation (ICST), Montreal, QC, Canada, IEEE (17-21 April 2012) 21–30 


minimise the number of trace sequences generated from a model that do not correspond to any existing execution traces minimise the number of trace sequences that are excluded from a model

Seach-Based Model Generation

Model Inference Framework

slide-17
SLIDE 17

Subject: Kate bug reports - KDE Bugtracking system

5583 bug issues reported since 2000 - 1/8 721 STR pattern

Search algorithms: multi-objective GA, NSGA-II Benchmark tool: KLFA

Experimental Setting

slide-18
SLIDE 18

RQ0: What are the prevalence and the characteristics of the trace events generated? RQ1: What are the performance of multi-objective

  • ptimisation compared to the benchmark model inference

technique, KLFA, in terms of the hypervolume, running time and the number of solutions? RQ2: What is the fault revealing ability of the models inferred?

Three Research Questions

slide-19
SLIDE 19

RQ0 Example of Trace Events Generated

721 bug reports 452 user events files 265 unique trace events

slide-20
SLIDE 20

RQ1 Performance of the Algorithms - Three Objectives

slide-21
SLIDE 21

KLFA

slide-22
SLIDE 22

KLFA

slide-23
SLIDE 23

KLFA

slide-24
SLIDE 24
slide-25
SLIDE 25

S12 S4

  • pen_kate

S23 start_kate S34

  • pen_file

S3 install_kate S10 change_keyboard_setting S29 ctrl S16 set_encoding S32 enter_text S20 create_session S17 settings S33

  • pen_file

S30 shift_enter S6 highlight_line S36 add_file S15

  • pen_kate

S31 enter_text S5 find S8

  • pen_file

S9 run_command S26

  • pen_file

S13 enable_show_sidebar S25 enter_text S28 alt_t_h S18 add_order_mark S7 set_sidebar_document_display S24 select_remote_file S2 click_action S14 click_button S1 click_button S22 close_kate enter_text create_session settings

  • pen_file

S11 enter_text S19 move_cursor S35 ctrl S39 enter_text S37 copy S38

  • pen_command_line

S27 run_script S21 move_cursor

slide-26
SLIDE 26

RQ1 Performance of the Algorithms - Quality Metrics

slide-27
SLIDE 27

RQ2 Fault-Revealing Ability of the Model

Divided 452 user events files into training and test sets based on submission time. Training set: 226 user events files from July 2009 to Oct. 2012 Test set: 226 user events files from Nov. 2012 to Feb. 2015 checking the number of trace events, which are in the test set, accepted by the models generated by the training set

If a bug trace event is accepted by a model, the model can be used to generate test trace sequence to capture this bug

slide-28
SLIDE 28

Inferring Test Models from Kate’s Bug Reports using Multi-objective Search