Skip to content

Commit

Permalink
Update codecov task (#110)
Browse files Browse the repository at this point in the history
* Update codecov task

* Fix lint errors
  • Loading branch information
andrewhickman committed May 21, 2024
1 parent bc4b532 commit a36e24e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 12 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ jobs:
run: |
cargo tarpaulin --verbose --packages prost-reflect prost-reflect-tests --all-features --timeout 120 --out xml
- name: Upload to codecov.io
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}
15 changes: 4 additions & 11 deletions prost-reflect/src/dynamic/fields.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ use std::{
};

use crate::{
Cardinality, ExtensionDescriptor, FieldDescriptor, Kind, MessageDescriptor, OneofDescriptor,
Value,
ExtensionDescriptor, FieldDescriptor, Kind, MessageDescriptor, OneofDescriptor, Value,
};

use super::unknown::{UnknownField, UnknownFieldSet};

pub(crate) trait FieldDescriptorLike: fmt::Debug {
#[cfg(feature = "text-format")]
fn text_name(&self) -> &str;
fn number(&self) -> u32;
fn default_value(&self) -> Value;
Expand All @@ -22,7 +22,6 @@ pub(crate) trait FieldDescriptorLike: fmt::Debug {
fn supports_presence(&self) -> bool;
fn kind(&self) -> Kind;
fn is_group(&self) -> bool;
fn cardinality(&self) -> Cardinality;
fn is_list(&self) -> bool;
fn is_map(&self) -> bool;
fn is_packed(&self) -> bool;
Expand Down Expand Up @@ -392,6 +391,7 @@ impl ValueOrUnknown {
}

impl FieldDescriptorLike for FieldDescriptor {
#[cfg(feature = "text-format")]
fn text_name(&self) -> &str {
self.name()
}
Expand Down Expand Up @@ -428,10 +428,6 @@ impl FieldDescriptorLike for FieldDescriptor {
self.is_group()
}

fn cardinality(&self) -> Cardinality {
self.cardinality()
}

fn is_list(&self) -> bool {
self.is_list()
}
Expand All @@ -450,6 +446,7 @@ impl FieldDescriptorLike for FieldDescriptor {
}

impl FieldDescriptorLike for ExtensionDescriptor {
#[cfg(feature = "text-format")]
fn text_name(&self) -> &str {
self.json_name()
}
Expand Down Expand Up @@ -486,10 +483,6 @@ impl FieldDescriptorLike for ExtensionDescriptor {
self.is_group()
}

fn cardinality(&self) -> Cardinality {
self.cardinality()
}

fn is_list(&self) -> bool {
self.is_list()
}
Expand Down

0 comments on commit a36e24e

Please sign in to comment.