SciFe: Scala framework for efficient enumeration of data structures with invariants

We introduce SciFe, a tool for automated generation of complex structures, suitable for tasks such as automated testing and synthesis. SciFe is capable of exhaustive, memoized enumeration of values from finite or infinite domains. SciFe is based on the concept of an enumerator, defined as an efficiently computable bijection between natural numbers and values from a given set. SciFe introduces higher-order enumerators which define enumerators that depend on additional parameters. SciFe also includes combinators that can construct more complex enumerators from existing ones while preserving exhaustiveness and efficiency. SciFe is a Scala library that implements a domain-specific language. This tool demo presents an overview of SciFe as well as its use to generate complex structures such as search trees and models of class hierarchies. Our experiments demonstrate better performance and shorter specifications when compared to existing approaches.

[1]  Darko Marinov,et al.  Automated testing of refactoring engines , 2007, ESEC-FSE '07.

[2]  Sarfraz Khurshid,et al.  Test generation through programming in UDITA , 2010, 2010 ACM/IEEE 32nd International Conference on Software Engineering.

[3]  Fabio Fioravanti,et al.  Generation of Test Data Structures Using Constraint Logic Programming , 2012, TAP@TOOLS.

[4]  Koen Claessen,et al.  QuickCheck: a lightweight tool for random testing of Haskell programs , 2011, SIGP.

[5]  Meng Wang,et al.  Feat: functional enumeration of algebraic types , 2012, Haskell.

[6]  Colin Runciman,et al.  Smallcheck and lazy smallcheck: automatic exhaustive testing for small values , 2008, Haskell '08.

[7]  Sarfraz Khurshid,et al.  Software assurance by bounded exhaustive testing , 2004, IEEE Transactions on Software Engineering.

[8]  Daniel Jackson,et al.  Alloy: a lightweight object modelling notation , 2002, TSEM.

[9]  Sarfraz Khurshid,et al.  Software Assurance by Bounded Exhaustive Testing , 2005, IEEE Trans. Software Eng..

[10]  Johan Jeuring,et al.  Enumerating Well-Typed Terms Generically , 2009, AAIP.

[11]  Bertrand Meyer,et al.  Experimental assessment of random testing for object-oriented software , 2007, ISSTA '07.

[12]  Bertrand Meyer,et al.  ARTOO: adaptive random testing for object-oriented software , 2008, ICSE.

[13]  Ivan Kuraj,et al.  Interactive Code Generation , 2013 .

[14]  Viktor Kuncak,et al.  Synthesis modulo recursive functions , 2013, OOPSLA.

[15]  Ruzica Piskac,et al.  Complete completion using types and weights , 2013, PLDI.

[16]  Martin Odersky,et al.  Instant pickles: generating object-oriented pickler combinators for fast and extensible serialization , 2013, OOPSLA.

[17]  Viktor Kuncak,et al.  Constraints as control , 2012, POPL '12.

[18]  Darko Marinov,et al.  A Comparison of Constraint-Based and Sequence-Based Generation of Complex Input Data Structures , 2010, 2010 Third International Conference on Software Testing, Verification, and Validation Workshops.

[19]  Sarfraz Khurshid,et al.  Korat: automated testing based on Java predicates , 2002, ISSTA '02.

[20]  Michael D. Ernst,et al.  Randoop: feedback-directed random testing for Java , 2007, OOPSLA '07.