Compare commits

..

No commits in common. "0a4019ea19d0d4d6b3cbdc88108408788b801772" and "9dd2da3cc4aa04be962894a2d9380100fdc49817" have entirely different histories.

2 changed files with 2 additions and 23 deletions

View file

@ -161,7 +161,7 @@ impl<D: Clone> SymbolBuilder<KeyAndCertBundle<D>> for DefaultBuilder {
target: &<KeyAndCertBundle<D> as Resource>::Artifact,
(cert_chain, key): <Self::Prerequisites as ToArtifact>::Artifact,
) -> Self::Symbol {
ConcatSymbol::new([key.0, cert_chain.0], target.0.clone())
ConcatSymbol::new([cert_chain.0, key.0], target.0.clone())
}
}

View file

@ -128,9 +128,7 @@ macro_rules! runnable_for_tuple {
#[allow(unused)]
fn run<_R: SymbolRunner>(&self, runner: &_R, force: bool) -> Result<bool, Box<dyn Error>> {
let ($($name,)*) = self;
let mut result = false;
$(result = runner.run_symbol($name, force)? || result;)*
Ok(result)
Ok($(runner.run_symbol($name, force)? || )* false)
}
}
);
@ -344,23 +342,4 @@ mod test {
setup.add(TestResource("A", "B")).unwrap();
assert_eq!(*count.borrow(), 0);
}
#[test]
fn correctly_handles_symbol_tuples() {
let (count, setup) = get_setup();
setup.run_symbol((TestSymbol { reached: false }, TestSymbol { reached: false }), false).unwrap();
assert_eq!(*count.borrow(), 2);
let (count, setup) = get_setup();
setup.run_symbol((TestSymbol { reached: true }, TestSymbol { reached: false }), false).unwrap();
assert_eq!(*count.borrow(), 1);
let (count, setup) = get_setup();
setup.run_symbol((TestSymbol { reached: false }, TestSymbol { reached: true }), false).unwrap();
assert_eq!(*count.borrow(), 1);
let (count, setup) = get_setup();
setup.run_symbol((TestSymbol { reached: true }, TestSymbol { reached: true }), true).unwrap();
assert_eq!(*count.borrow(), 2);
}
}