Skip to content

lucas-manuel/invariant-examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Invariant Examples

Foundry

Overview

This repository functions as an accessible example for Foundry developers to experiment and learn about invariant testing.

This repository is a work in progress, and will be updated continuously. Issues with suggestions are encouraged!

Setup

This project was built using Foundry. Refer to installation instructions here.

git clone [email protected]:lucas-manuel/invariant-example.git
cd invariant-example
forge install

Running Tests

Foundry considers all functions that start with invariant_ to be invariant tests. To run them, you can use the following commands:

  • To run open invariant tests: make open-invariant
  • To run bounded invariant tests: make bounded-invariant
  • To run unbounded invariant tests: make unbounded-invariant

Call Summaries

invariant_call_summary functions are not invariants, they are used to illustrate how the probability distribution of function calls within a given invariant test works.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published