Re: "setup.py test" is being naughty
Local testing works well for a number of unit tests when run from the IDE.
We of course run full suite of tests via docker environment but our own
test classess/modules are run using local python environment. It's the
easiest way to configure local python virtualenv with IntelliJ/Pycharm for
one. You can - in recent version of PyCharm/IntelliJ - have docker python
environment setup, but there are certain downsides of using it
(speed/mounting local volumes with sources etc.).
So I think we should not really discourage running at least some tests
locally. Maybe (if there are not many of those) we could identify the tests
which require the full-blown docker environment and mark them with
skipUnless and only have them executed when we are inside dockerized
environment for unit tests ?
On Wed, Oct 3, 2018 at 1:48 PM Holden Karau <holden@xxxxxxxxxxxxx> wrote:
> I think (in the short term) discontinuing local testing and telling folks
> to use the docker based approach makes more sense (many of the tests have a
> complex set of dependencies that don't make sense to try and test locally).
> What do other folks think?
> On Wed, Oct 3, 2018 at 4:45 AM EKC (Erik Cederstrand)
> <EKC@xxxxxxxxxxxxx.invalid> wrote:
> > The test suite is also trying to create /usr/local/bin/airflow, which
> > means I can't run the test suite on a machine that actually uses
> > /usr/local/bin/airflow. And the default config file doesn't find the
> > server I set up locally. I'm trying the Docker-based test environment
> > It seems the local test setup either needs polishing or should be
> > discontinued.
> > Erik
> > ________________________________
> > From: EKC (Erik Cederstrand)
> > Sent: Wednesday, October 3, 2018 12:01:00 PM
> > To: dev@xxxxxxxxxxxxxxxxxxxxxxxxxxxx
> > Subject: "setup.py test" is being naughty
> > Hi all,
> > I wanted to contribute a simple patch, and as a good open source citizen
> > wanted to also contribute a test. So I git clone from GitHub, create a
> > virtualenv and run "setup.py test". First experience is that my
> > /etc/krb5.conf is overwritten, which means my account is locked out of
> > systems here at work. I recovered from that, only to find out that
> > ~/.ssh/id_rsa and ~/.ssh/id_rsa.pub were also overwritten. Now I'm not
> > amused.
> > Did I miss something in CONTRIBUTING.md?
> > Erik
> Twitter: https://twitter.com/holdenkarau
> Books (Learning Spark, High Performance Spark, etc.):
> https://amzn.to/2MaRAG9 <https://amzn.to/2MaRAG9>
> YouTube Live Streams: https://www.youtube.com/user/holdenkarau
*Jarek Potiuk, Principal Software Engineer*
Mobile: +48 660 796 129