Re: [PATCH V4 0/8] libgpiod: Add Rust bindings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Jul 16, 2022 at 12:44 PM Bartosz Golaszewski <brgl@xxxxxxxx> wrote:
>
> This does seem to build the test-suite but there's no single
> executable in target/debug/deps. Instead it seems that every test
> section gets its own executable. Does 'cargo test' run them
> separately? Or is there a single binary including all of them
> somewhere else?

Yeah, for `tests/` tests it seems to create several binaries. For
`#[test]`s, they are put in a single binary.

Another solution for both of those (from
https://github.com/rust-lang/cargo/issues/5999) is `.cargo/config` (in
the project folder):

    [target.x86_64-unknown-linux-gnu]
    runner = 'sudo -E'

Which indeed seems to work for both `tests/` and `#[test]`s.

However, I don't think that one works for doctests, though (at least I
don't see it executing `rustdoc` with the runner)... But maybe you
don't need privileges for those.

Cheers,
Miguel



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux