pub enum DiffRiskRule {
WeakenedTests,
AddedSuppression,
TestOnlyBranch,
DivergedCloneSibling,
AddedDependency,
}Expand description
The rule that owns a diff-risk finding.
Variants§
WeakenedTests
The diff weakened tests. The kind field tells how.
AddedSuppression
The diff added a lint, type-check, coverage or Fallow suppression.
TestOnlyBranch
The diff added a test-environment branch to a non-test source file.
DivergedCloneSibling
The diff edited one copy of a base clone group, and no sibling changed.
AddedDependency
The diff added a dependency to a package.json.
Implementations§
Source§impl DiffRiskRule
impl DiffRiskRule
Sourcepub const fn code(self) -> &'static str
pub const fn code(self) -> &'static str
The stable rule code. It is also the rules config key and the
suppression token.
Sourcepub fn sarif_rule_id(self) -> String
pub fn sarif_rule_id(self) -> String
The SARIF rule id, fallow/<code>.
Sourcepub const fn description(self) -> &'static str
pub const fn description(self) -> &'static str
A short description for SARIF rule metadata and human output.
Trait Implementations§
Source§impl Clone for DiffRiskRule
impl Clone for DiffRiskRule
impl Copy for DiffRiskRule
Source§impl Debug for DiffRiskRule
impl Debug for DiffRiskRule
Source§impl<'de> Deserialize<'de> for DiffRiskRule
impl<'de> Deserialize<'de> for DiffRiskRule
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>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for DiffRiskRule
Source§impl Hash for DiffRiskRule
impl Hash for DiffRiskRule
Source§impl Ord for DiffRiskRule
impl Ord for DiffRiskRule
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for DiffRiskRule
impl PartialEq for DiffRiskRule
Source§impl PartialOrd for DiffRiskRule
impl PartialOrd for DiffRiskRule
Source§impl Serialize for DiffRiskRule
impl Serialize for DiffRiskRule
impl StructuralPartialEq for DiffRiskRule
Auto Trait Implementations§
impl Freeze for DiffRiskRule
impl RefUnwindSafe for DiffRiskRule
impl Send for DiffRiskRule
impl Sync for DiffRiskRule
impl Unpin for DiffRiskRule
impl UnsafeUnpin for DiffRiskRule
impl UnwindSafe for DiffRiskRule
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.