ISSTA2020

ProFL: a fault localization framework for Prolog

George Thompson, Allison K. Sullivan

7 citations

Abstract

Prolog is a declarative, first-order logic that has been used in a variety of domains to implement heavily rules-based systems. However, it is challenging to write a Prolog program correctly. Fortunately, the SWI-Prolog environment supports a unit testing framework, plunit, which enables developers to systematically check for correctness. However, knowing a program is faulty is just the first step. The developer then needs to fix the program which means the developer needs to determine what part of the program is faulty. ProFL is a fault localization tool that adapts imperativebased fault localization techniques to Prolog's declarative environment. ProFL takes as input a faulty Prolog program and a plunit test suite. Then, ProFL performs fault localization and returns a list of suspicious program clauses to the user. Our toolset encompasses two different techniques: ProFL s , a spectrum-based technique, and ProFL m , a mutation-based technique. This paper describes our Python implementation of ProFL, which is a commandline tool, released as an open-source project on GitHub ( https: //github.com/geoorge1d127/ProFL ). Our experimental results show ProFL is accurate at localizing faults in our benchmark programs. CCS CONCEPTS • Software and its engineering → Software testing and debugging.