Skip to content

Commit

Permalink
refactor: deal with unused code warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
vbarua committed Aug 30, 2024
1 parent 5051991 commit f52f01c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions datafusion/substrait/tests/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
// under the License.

#[cfg(test)]
pub(crate) mod test {
pub mod test {
use datafusion::catalog_common::TableReference;
use datafusion::datasource::empty::EmptyTable;
use datafusion::prelude::SessionContext;
Expand All @@ -29,14 +29,14 @@ pub(crate) mod test {
use substrait::proto::rel::RelType;
use substrait::proto::{Plan, ReadRel, Rel};

pub(crate) fn read_json(path: &str) -> Plan {
pub fn read_json(path: &str) -> Plan {
serde_json::from_reader::<_, Plan>(BufReader::new(
File::open(path).expect("file not found"),
))
.expect("failed to parse json")
}

pub(crate) struct TestSchemaCollector {
pub struct TestSchemaCollector {
ctx: SessionContext,
}

Expand All @@ -47,7 +47,7 @@ pub(crate) mod test {
}
}

pub(crate) fn generate_context_from_plan(plan: &Plan) -> SessionContext {
pub fn generate_context_from_plan(plan: &Plan) -> SessionContext {
let mut schema_collector = Self::new();

for plan_rel in plan.relations.iter() {
Expand Down

0 comments on commit f52f01c

Please sign in to comment.