Remove dead BSON related tests (#10458)

Those tests where behind a feature flag `bson` that is never defined in
`Cargo.toml`

Remove them.
This commit is contained in:
Stefan Holderbach 2023-09-21 20:01:49 +02:00 committed by GitHub
parent addf8ca942
commit 0c7a8e3634
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 0 additions and 71 deletions

View File

@ -29,59 +29,6 @@ fn parses_csv() {
}) })
} }
// sample.bson has the following format:
// ━━━━━━━━━━┯━━━━━━━━━━━
// _id │ root
// ──────────┼───────────
// [object] │ [9 items]
// ━━━━━━━━━━┷━━━━━━━━━━━
//
// the root value is:
// ━━━┯━━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━┯━━━━━━━━━━
// # │ _id │ a │ b │ c
// ───┼───────────────────┼─────────────────────────┼──────────┼──────────
// 0 │ [object] │ 1.000000000000000 │ hello │ [2 items]
// 1 │ [object] │ 42.00000000000000 │ whel │ hello
// 2 │ [object] │ [object] │ │
// 3 │ [object] │ │ [object] │
// 4 │ [object] │ │ │ [object]
// 5 │ [object] │ │ │ [object]
// 6 │ [object] │ [object] │ [object] │
// 7 │ [object] │ <date value> │ [object] │
// 8 │ 1.000000 │ <decimal value> │ [object] │
//
// The decimal value is supposed to be π, but is currently wrong due to
// what appears to be an issue in the bson library that is under investigation.
//
#[cfg(feature = "bson")]
#[test]
fn parses_bson() {
let actual = nu!(
cwd: "tests/fixtures/formats",
"open sample.bson | get root | select 0 | get b"
);
assert_eq!(actual.out, "hello");
}
#[cfg(feature = "bson")]
#[test]
fn parses_more_bson_complexity() {
let actual = nu!(
cwd: "tests/fixtures/formats", pipeline(
r#"
open sample.bson
| get root
| select 6
| get b
| get '$binary_subtype'
"#
));
assert_eq!(actual.out, "function");
}
// sample.db has the following format: // sample.db has the following format:
// //
// ╭─────────┬────────────────╮ // ╭─────────┬────────────────╮

View File

@ -1,17 +0,0 @@
#[cfg(feature = "bson")]
#[test]
fn table_to_bson_and_back_into_table() {
use nu_test_support::{nu, pipeline};
let actual = nu!(
cwd: "tests/fixtures/formats", pipeline(
r#"
open sample.bson
| to bson
| from bson
| get root
| get 1.b
"#
));
assert_eq!(actual.out, "whel");
}

View File

@ -1,4 +1,3 @@
mod bson;
mod csv; mod csv;
#[cfg(feature = "extra")] #[cfg(feature = "extra")]
mod html; mod html;

Binary file not shown.