Coder Social home page Coder Social logo

faultify's Introduction

Nuget Nuget Tester Join us on Discord Donate

Byte Code Dotnet Mutation Utility

Faultify provides a quick simple way to realize dotnet mutation testing at the byte code level. It imitates the bad programmer by deliberately introducing errors. A test is assumed to fail after an introduced mutation, the test is likely to be error-prone if it instead succeeds.

disclaimer: faultify is just released and bugs can be expected, please open a issue if you get any.

Getting Started

Commandline Options

  -t, --testProjectName    Required. The path pointing to the test project project file.
  -r, --reportPath         The path were the report will be saved.
  -f, --reportFormat       (Default: json) Type of report to be generated, options: 'pdf', 'html', 'json'
  -p, --parallel           (Default: 1) Defines how many test sessions are ran at the same time.
  -l, --mutationLevel      (Default: Detailed) The mutation level indicating the test depth.
  
  --help                   Display this help screen.
  --version                Display version information.

Install / Run

dotnet tool install --global faultify --version 0.2.0
faultify -t YourTestProject.csproj -f html

This generates a 'HTML' report for the project 'YourTestProject.csproj' at the default executable location in the folder '/FaultifyOutput'.

Features

Functional Features

  • Mutate Arithmetic (+, -, /, *, %) Operators.
  • Mutate Assignment Expressions (+=, -=, /=, *=, %=, --, ++).
  • Mutate Equivalence Operators (==, !=).
  • Mutate Logical Operators (&&, ||).
  • Change bitwise operators (^,|, &).
  • Mutate Branching statements (if(condition), if(!condition))
  • Mutate Variable Literals (true, false).
    • Support for other types.
  • Mutate Constant Fields (string, number, boolean).
  • Mutate Array initializations (Only arrays larger than 2 elements, all C# types)
  • Build mutation report (HTML/PDF).
  • Mutation test algorithm.

Non-Functional Features

  • Cross-platform .net core compatibility.
  • Nunit/Xunit/Msunit support via dotnet test.
  • Runnable from console.
  • All dotnet languages (F#, C#, visualbaisc) support.

Todo

  • Implement member exclusion.
  • Implement line number display
  • Improve reporting functionality
  • Implement assembly testing in memory

Application Preview

drawing

Solution Projects

Solution Item Description
Faultify.Cli Contains the faultify executable mutation dotnet utility.
Faultify.Analyze Contains the code that analyzes and searches for mutations
Faultify.TestRunner Contains the code that runs the mutation test process
Faultify.Report Contains the code that generates a report
/Bechmarks Contains a benchmark project and tests that can be used for mutation testing with faultify/stryker.

faultify's People

Contributors

timonpost avatar hyperoceanic avatar 96radhikajadhav avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.