Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests/* not shipped in crate, resulting in unused [dev-dependencies]

Closed
kentfredric opened this issue Oct 22, 2019 · 0 comments
Closed

Comments

@kentfredric
Copy link

kentfredric commented Oct 22, 2019

[dev-dependencies.automod]
version = "0.1"

[dev-dependencies.rustversion]
version = "0.1"

[dev-dependencies.serde_bytes]
version = "0.11"

[dev-dependencies.serde_derive]
version = "1.0"

[dev-dependencies.serde_stacker]
version = "0.1"

[dev-dependencies.trybuild]
version = "1.0"
$ ls
Cargo.toml  Cargo.toml.orig  LICENSE-APACHE  LICENSE-MIT  README.md  src
$ grep 'automod' -r .
./Cargo.toml.orig:automod = "0.1"
./Cargo.toml:[dev-dependencies.automod]
$ grep 'rustversion' -r .
./Cargo.toml.orig:rustversion = "0.1"
./Cargo.toml:[dev-dependencies.rustversion]
 $ grep 'serde_bytes' -r .
./Cargo.toml.orig:serde_bytes = "0.11"
./src/de.rs:    /// use serde_bytes::ByteBuf;
./src/de.rs:    /// use serde_bytes::ByteBuf;
./Cargo.toml:[dev-dependencies.serde_bytes]
kent@katipo2 ~/.cpanm/work/1571714539.20228/serde_json-1.0.41 $ grep 'serde_derive' -r .
./Cargo.toml.orig:serde_derive = "1.0"
./Cargo.toml:[dev-dependencies.serde_derive]
kent@katipo2 ~/.cpanm/work/1571714539.20228/serde_json-1.0.41 $ grep 'serde_stacker' -r .
./Cargo.toml.orig:serde_stacker = "0.1"
./Cargo.toml.orig:# stack adapter provided by the serde_stacker crate. Additionally you will need
./src/de.rs:    /// growing stack adapter provided by the serde_stacker crate. Additionally
./src/de.rs:    ///     let deserializer = serde_stacker::Deserializer::new(&mut deserializer);
./Cargo.toml:[dev-dependencies.serde_stacker]
$ grep 'trybuild' -r .
./Cargo.toml.orig:trybuild = "1.0"
./Cargo.toml:[dev-dependencies.trybuild]
cargo test
    Updating crates.io index
  Downloaded automod v0.1.2
  Downloaded rustversion v0.1.4
  Downloaded trybuild v1.0.17
  Downloaded toml v0.5.3
   Compiling proc-macro2 v1.0.6
   Compiling unicode-xid v0.2.0
   Compiling syn v1.0.5
   Compiling cc v1.0.46
   Compiling ryu v1.0.2
   Compiling libc v0.2.65
   Compiling serde v1.0.101
   Compiling itoa v0.4.4
   Compiling cfg-if v0.1.10
   Compiling lazy_static v1.4.0
   Compiling glob v0.3.0
   Compiling termcolor v1.0.5
   Compiling psm v0.1.5
   Compiling stacker v0.1.6
   Compiling quote v1.0.2
   Compiling serde_derive v1.0.101
   Compiling rustversion v0.1.4
   Compiling automod v0.1.2
   Compiling toml v0.5.3
   Compiling serde_json v1.0.41
   Compiling serde_bytes v0.11.2
   Compiling serde_json v1.0.41 (./serde_json-1.0.41)
   Compiling serde_stacker v0.1.1
   Compiling trybuild v1.0.17
    Finished dev [unoptimized + debuginfo] target(s) in 1m 38s
     Running target/debug/deps/serde_json-92f70e40abbd2b3f

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out

   Doc-tests serde_json

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out

This combination of choices is a waste of time for everyone who attempts to run tests on the shipped crate, and makes quality-assurance on published crates nigh impossible.

Granted, some of this exposes inadequacies in cargo, like:

But its presently a bug in the crate itself.

kentfredric added a commit to kentfredric/rust-dev-overlay that referenced this issue Nov 6, 2019
Though currently, these tests are nothing more than an almost no-op
of "it compiles", as the entire test suite is stripped by upstream
during shipping, and subsequently, a whole bunch of unused
dev-dependencies are patched out to keep things simple.

Bug: serde-rs/json#578
Package-Manager: Portage-2.3.75, Repoman-2.3.16
Signed-off-by: Kent Fredric <kentnl@gentoo.org>
kentfredric added a commit to kentfredric/rust-dev-overlay that referenced this issue Nov 19, 2019
Though currently, these tests are nothing more than an almost no-op
of "it compiles", as the entire test suite is stripped by upstream
during shipping, and subsequently, a whole bunch of unused
dev-dependencies are patched out to keep things simple.

Bug: serde-rs/json#578
Package-Manager: Portage-2.3.75, Repoman-2.3.16
Signed-off-by: Kent Fredric <kentnl@gentoo.org>
kentfredric added a commit to kentfredric/rust-dev-overlay that referenced this issue Jan 6, 2020
Though currently, these tests are nothing more than an almost no-op
of "it compiles", as the entire test suite is stripped by upstream
during shipping, and subsequently, a whole bunch of unused
dev-dependencies are patched out to keep things simple.

Bug: serde-rs/json#578
Package-Manager: Portage-2.3.75, Repoman-2.3.16
Signed-off-by: Kent Fredric <kentnl@gentoo.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant