Module fera_graph::arbitrary
[−]
[src]
Generate arbitrary graphs to be use in quickcheck tests.
This requires enabling quickcheck
feature.
Examples:
Testing WithBuilder::new_gn_connected
against Components::is_connected
:
#[macro_use] extern crate quickcheck; extern crate fera_graph; use fera_graph::prelude::*; use fera_graph::algs::Components; use fera_graph::arbitrary::GnConnected; use quickcheck::quickcheck; fn main() { fn tree(g: GnConnected<StaticGraph>) -> bool { let GnConnected(g) = g; g.is_connected() } quickcheck(tree as fn(GnConnected<StaticGraph>) -> bool); }
Structs
Gn |
A wrapper to create arbitrary graphs using |
GnConnected |
A wrapper to create arbitrary graphs using |
GnConnectedWithEdgeProp |
A wrapper to create arbitrary graphs with an edge property using
|
GnConnectedWithVertexProp |
A wrapper to create arbitrary graphs with a vertex property using
|
GnWithEdgeProp |
A wrapper to create arbitrary graphs with an edge property using |
GnWithVertexProp |
A wrapper to create arbitrary graphs with a vertex property using |