linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kent Gibson <warthog618@gmail.com>
To: Bartosz Golaszewski <brgl@bgdev.pl>
Cc: "Viresh Kumar" <viresh.kumar@linaro.org>,
	"Linus Walleij" <linus.walleij@linaro.org>,
	"Vincent Guittot" <vincent.guittot@linaro.org>,
	linux-gpio@vger.kernel.org,
	"Miguel Ojeda" <miguel.ojeda.sandonis@gmail.com>,
	"Wedson Almeida Filho" <wedsonaf@gmail.com>,
	"Alex Bennée" <alex.bennee@linaro.org>,
	stratos-dev@op-lists.linaro.org,
	"Gerard Ryan" <g.m0n3y.2503@gmail.com>,
	"Alex Gaynor" <alex.gaynor@gmail.com>,
	"Boqun Feng" <boqun.feng@gmail.com>,
	"Gary Guo" <gary@garyguo.net>,
	"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
	y86-dev <y86-dev@protonmail.com>
Subject: Re: [libgpiod][PATCH V9 7/8] bindings: rust: Add tests for libgpiod crate
Date: Wed, 9 Nov 2022 18:36:09 +0800	[thread overview]
Message-ID: <Y2uCmSiSatVQD/Hb@sol> (raw)
In-Reply-To: <Y2t30tYwSqGW8HlA@sol>

On Wed, Nov 09, 2022 at 05:50:10PM +0800, Kent Gibson wrote:
> On Wed, Nov 09, 2022 at 10:30:55AM +0100, Bartosz Golaszewski wrote:
> > On Mon, Nov 7, 2022 at 10:58 AM Viresh Kumar <viresh.kumar@linaro.org> wrote:
> > >
> > > Add tests for the rust bindings, quite similar to the ones in cxx
> > > bindings.
> > >
> > > Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
> > 
> > Without modifying udev rules on my system - is there a one-liner I
> > could use to launch the tests? I guess using cargo as sudo is wrong
> > but the executables are there so can I somehow run them all at once as
> > if running `cargo test`?
> > 
> 
> I use:
> 
> sudo /home/dev/.cargo/bin/cargo test
> 
> so using the cargo installed in the dev account on my test machine.
> 
> That way I can build, clippy and generate docs etc as dev, but require
> sudo for the tests.
> 
> I would love to know how to do it without the sudo, but as you suggest,
> that would probably require some udev magic or something to set the
> configfs and sysfs file permissions, as well as the gpiochips themselves,
> and given the above works for me I've not had sufficient incentive to
> look into it.
> 

And just to be clear, my libgpiod test machine is a VM, so running as
root isn't a huge issue.

Being able to run tests against gpiosim on a real machine, without
requiring root, would be really nice to have though.

Cheers,
Kent.


  reply	other threads:[~2022-11-09 10:36 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-07  9:57 [libgpiod][PATCH V9 0/8] libgpiod: Add Rust bindings Viresh Kumar
2022-11-07  9:57 ` [libgpiod][PATCH V9 1/8] bindings: rust: Add libgpiod-sys rust crate Viresh Kumar
2022-11-09  9:07   ` Bartosz Golaszewski
2022-11-14 10:04     ` Viresh Kumar
2022-11-14 10:30       ` Bartosz Golaszewski
2022-11-07  9:57 ` [libgpiod][PATCH V9 2/8] bindings: rust: Add pre generated bindings for libgpiod-sys Viresh Kumar
2022-11-07  9:57 ` [libgpiod][PATCH V9 3/8] bindings: rust: Add gpiosim crate Viresh Kumar
2022-11-07  9:57 ` [libgpiod][PATCH V9 4/8] bindings: rust: Add pre generated bindings for gpiosim Viresh Kumar
2022-11-07  9:57 ` [libgpiod][PATCH V9 5/8] bindings: rust: Add libgpiod crate Viresh Kumar
2022-11-07  9:57 ` [libgpiod][PATCH V9 6/8] bindings: rust: Add examples to " Viresh Kumar
2022-11-10 18:26   ` Bartosz Golaszewski
2022-11-14 10:03     ` Viresh Kumar
2022-11-14 10:29       ` Bartosz Golaszewski
2022-11-14 10:42         ` Viresh Kumar
2022-11-07  9:57 ` [libgpiod][PATCH V9 7/8] bindings: rust: Add tests for " Viresh Kumar
2022-11-09  9:30   ` Bartosz Golaszewski
2022-11-09  9:50     ` Kent Gibson
2022-11-09 10:36       ` Kent Gibson [this message]
2022-11-09  9:54     ` Linus Walleij
2022-11-09 10:12     ` Björn Roy Baron
2022-11-07  9:57 ` [libgpiod][PATCH V9 8/8] bindings: rust: Integrate building of bindings with make Viresh Kumar
2022-11-14 21:49 ` [libgpiod][PATCH V9 0/8] libgpiod: Add Rust bindings Bartosz Golaszewski
2022-11-16  1:12   ` Kent Gibson
2022-11-18 16:44     ` Gary Guo
2022-11-18 17:24       ` Kent Gibson
2022-11-16 10:29 ` Bartosz Golaszewski
2022-11-17  7:31   ` Viresh Kumar
2022-11-17  9:06     ` Bartosz Golaszewski
2022-11-17  9:56       ` Viresh Kumar
2022-11-17 10:18         ` Bartosz Golaszewski
2022-11-17 10:40           ` Viresh Kumar
2022-11-17 10:48             ` Bartosz Golaszewski
2022-11-17 10:55               ` Viresh Kumar
2022-11-17 11:05                 ` Bartosz Golaszewski
2022-11-17 11:15                   ` Viresh Kumar
2022-11-17 12:32                     ` Bartosz Golaszewski
2022-11-17 10:51           ` Miguel Ojeda
2022-11-17 11:04             ` Viresh Kumar
2022-11-17 11:07         ` Miguel Ojeda
2022-11-17 11:15           ` Bartosz Golaszewski
2022-11-17 11:25             ` Viresh Kumar
2022-11-17 12:18               ` Bartosz Golaszewski
2022-11-18  9:35                 ` Viresh Kumar
2022-11-18  9:38                   ` Bartosz Golaszewski
2022-11-18  9:41                     ` Viresh Kumar
2022-11-18  9:42                       ` Bartosz Golaszewski
2022-11-17 13:05               ` Kent Gibson
2022-11-17  8:12   ` Linus Walleij
2022-11-17  8:37     ` Bartosz Golaszewski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Y2uCmSiSatVQD/Hb@sol \
    --to=warthog618@gmail.com \
    --cc=alex.bennee@linaro.org \
    --cc=alex.gaynor@gmail.com \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun.feng@gmail.com \
    --cc=brgl@bgdev.pl \
    --cc=g.m0n3y.2503@gmail.com \
    --cc=gary@garyguo.net \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=miguel.ojeda.sandonis@gmail.com \
    --cc=stratos-dev@op-lists.linaro.org \
    --cc=vincent.guittot@linaro.org \
    --cc=viresh.kumar@linaro.org \
    --cc=wedsonaf@gmail.com \
    --cc=y86-dev@protonmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).