multiobjective-search 0.1.1

Multi-objective shortest paths over Pareto frontiers: BOA*, BOBA*, EMOA*, NAMOA*dr, A*pex and their approximate, anytime and parallel variants
Documentation
//! The public brute-force reference against the test-only one.

use multiobjective_search::brute_force;
use proptest::prelude::*;

use crate::check::check;
use crate::fixtures::{Problem, problems};

/// Runs the public reference and checks it against the test oracle.
fn check_reference<const N: usize>(p: &Problem<N>) -> Result<(), TestCaseError> {
    check(p, &brute_force(&p.graph, p.start, |v| p.goals[*v]))
}

proptest! {
    /// Two objectives.
    #[test]
    fn two_objectives(p in problems::<2>()) {
        check_reference(&p)?;
    }

    /// Three objectives.
    #[test]
    fn three_objectives(p in problems::<3>()) {
        check_reference(&p)?;
    }
}