pub struct PresentedRevision {
pub revision: String,
pub tree: TreeState,
pub uncommitted: Vec<String>,
}Expand description
What a report was judged at: the revision, its tree, and the runs the checkout holds that the revision’s own ledger does not.
A verdict is always a verdict at something. evidence show judges the working tree;
evidence show --presented HEAD judges the checked-out commit as committed, from the
ledger committed in it — which is the reading a site built from that commit needs.
use majordomus_cli::evidence::{PresentedRevision, TreeState};
let here = PresentedRevision {
revision: "working_tree".into(),
tree: TreeState::Dirty,
uncommitted: vec![],
};
let json = serde_json::to_value(&here).unwrap();
assert_eq!(json["tree"], "dirty");
// nothing held uncommitted is absent, not an empty list to read past
assert!(json.get("uncommitted").is_none());Fields§
§revision: Stringworking_tree, or the full id of the commit judged as committed.
tree: TreeStateWhether that revision’s tree was its commit: for the working tree, the checkout’s state; for a commit, the checkout measured ignoring the ledger’s working copy and weakened by anything the caller knew.
uncommitted: Vec<String>The tests whose execution in the working copy of the ledger the presented commit’s
ledger does not hold, sorted. Read only to withhold proven, never to decide a
verdict; always empty for the working tree, whose ledger is itself the authority.
Trait Implementations§
Source§impl Clone for PresentedRevision
impl Clone for PresentedRevision
Source§fn clone(&self) -> PresentedRevision
fn clone(&self) -> PresentedRevision
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PresentedRevision
impl Debug for PresentedRevision
Source§impl<'de> Deserialize<'de> for PresentedRevision
impl<'de> Deserialize<'de> for PresentedRevision
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for PresentedRevision
Source§impl JsonSchema for PresentedRevision
impl JsonSchema for PresentedRevision
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreSource§impl PartialEq for PresentedRevision
impl PartialEq for PresentedRevision
Source§fn eq(&self, other: &PresentedRevision) -> bool
fn eq(&self, other: &PresentedRevision) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for PresentedRevision
impl Serialize for PresentedRevision
impl StructuralPartialEq for PresentedRevision
Auto Trait Implementations§
impl Freeze for PresentedRevision
impl RefUnwindSafe for PresentedRevision
impl Send for PresentedRevision
impl Sync for PresentedRevision
impl Unpin for PresentedRevision
impl UnsafeUnpin for PresentedRevision
impl UnwindSafe for PresentedRevision
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.