Skip to content

Enable GUI testing on Travis Linux builds via Xvfb #7887

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

Merged
merged 1 commit into from
Jul 11, 2018

Conversation

zware
Copy link
Member

@zware zware commented Jun 24, 2018

This enables GUI tests on the Travis Linux builds using xvfb-run. Unfortunately, there's an IDLE test case failing in Travis runs on my fork, which I don't understand and can't reproduce.

@ammaraskar
Copy link
Member

We're already pushing it as far as build times go with the newly added C coverage, let's make sure this isn't cutting it too close to 50 minutes. If so, we might have to split up the coverage build to run half the suite in one build and the other half in another.

@ammaraskar
Copy link
Member

For reference, 46 minutes on this build! https://travis-ci.org/python/cpython/jobs/395974908

@taleinat
Copy link
Contributor

taleinat commented Jun 24, 2018

Unfortunately, there's an IDLE test case failing in Travis runs on my fork, which I don't understand and can't reproduce.

While investigating that failure I encountered an issue which may or may not be the cause. See bpo-33951 and GH-7892.

@terryjreedy
Copy link
Member

I am not completely surprised that something fails on Linux. I am more surprised that it failed on Travis and not VSTS Linux (#7890). Cheryl Sabella helped write these tests and must have run them (on Ubuntu) then and since. Tal, do they pass on your Linux?

Is there any easy way to get the tcl/tk version Travis uses? I expanded system info at the top of
https://travis-ci.org/python/cpython/jobs/395980894
and there were lots of things not relevant to us. If nothing else, I could temporarily add a print to test_idle.

Anyway, I am looking into how eq(d.highlight_target.get(), elem[tag]) could possibly have the first item as 'c'. The problem is likely to be in the nested click_it and the event_generate calls. The latter seem to be a bit delicate.

@taleinat
Copy link
Contributor

Tal, do they pass on your Linux?

All tests pass on my Ubuntu 16.04 box. I ran the relevant test and all of the IDLE tests, both on current master and on this branch.

@terryjreedy
Copy link
Member

Copying the failure here.

FAIL: test_highlight_target_text_mouse (idlelib.idle_test.test_configdialog.HighPageTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/travis/build/python/cpython/Lib/idlelib/idle_test/test_configdialog.py", line 417, in test_highlight_target_text_mouse
    eq(d.highlight_target.get(), elem[tag])
AssertionError: 'c' != 'Normal Text'
- c
+ Normal Text

@terryjreedy
Copy link
Member

terryjreedy commented Jun 24, 2018

I restarted Travis after merging Tal's fix for bpo-33951 -- and it passes now.

@zware zware merged commit b12112b into python:master Jul 11, 2018
@miss-islington
Copy link
Contributor

Thanks @zware for the PR 🌮🎉.. I'm working now to backport this PR to: 2.7, 3.6, 3.7.
🐍🍒⛏🤖

@zware zware deleted the travis_gui branch July 11, 2018 19:10
@miss-islington
Copy link
Contributor

Sorry, @zware, I could not cleanly backport this to 3.7 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker b12112b5ba608cdd7a0962a6b18cad4fe58b46e6 3.7

@miss-islington
Copy link
Contributor

Sorry, @zware, I could not cleanly backport this to 2.7 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker b12112b5ba608cdd7a0962a6b18cad4fe58b46e6 2.7

@miss-islington
Copy link
Contributor

Sorry, @zware, I could not cleanly backport this to 3.6 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker b12112b5ba608cdd7a0962a6b18cad4fe58b46e6 3.6

CuriousLearner added a commit to CuriousLearner/cpython that referenced this pull request Jul 14, 2018
* master: (2633 commits)
  bpo-34087: Fix buffer overflow in int(s) and similar functions (pythonGH-8274)
  bpo-34108: Fix double carriage return in 2to3 on Windows (python#8271)
  bpo-4260: Document that ctypes.xFUNCTYPE are decorators (pythonGH-7924)
  bpo-33723: Fix test_time.test_thread_time() (pythonGH-8267)
  bpo-33967: Remove use of deprecated assertRaisesRegexp() (pythonGH-8261)
  bpo-34080: Fix a memory leak in the compiler. (pythonGH-8222)
  Enable GUI testing on Travis Linux builds via Xvfb (pythonGH-7887)
  bpo-23927: Make getargs.c skipitem() skipping 'w*'. (pythonGH-8192)
  bpo-33648: Remove PY_WARN_ON_C_LOCALE (pythonGH-7114)
  bpo-34092, test_logging: increase SMTPHandlerTest timeout (pythonGH-8245)
  Simplify __all__ in multiprocessing (pythonGH-6856)
  bpo-34083: Update dict order in Functional HOWTO (pythonGH-8230)
  Doc: Point to Simple statements section instead of PEP (pythonGH-8238)
  bpo-29442: Replace optparse with argparse in setup.py (pythonGH-139)
  bpo-33597: Add What's New for PyGC_Head (pythonGH-8236)
  Dataclasses: Fix example on 30.6.8, add method should receive a list rather than an integer. (pythonGH-8038)
  Fix documentation for input and output tutorial (pythonGH-8231)
  bpo-34009: Expand on platform support changes (pythonGH-8022)
  Factor-out two substantially identical code blocks. (pythonGH-8219)
  bpo-34031: fix incorrect usage of self.fail in two tests (pythonGH-8091)
  ...
CuriousLearner added a commit to CuriousLearner/cpython that referenced this pull request Jul 15, 2018
* master: (1159 commits)
  bpo-34087: Fix buffer overflow in int(s) and similar functions (pythonGH-8274)
  bpo-34108: Fix double carriage return in 2to3 on Windows (python#8271)
  bpo-4260: Document that ctypes.xFUNCTYPE are decorators (pythonGH-7924)
  bpo-33723: Fix test_time.test_thread_time() (pythonGH-8267)
  bpo-33967: Remove use of deprecated assertRaisesRegexp() (pythonGH-8261)
  bpo-34080: Fix a memory leak in the compiler. (pythonGH-8222)
  Enable GUI testing on Travis Linux builds via Xvfb (pythonGH-7887)
  bpo-23927: Make getargs.c skipitem() skipping 'w*'. (pythonGH-8192)
  bpo-33648: Remove PY_WARN_ON_C_LOCALE (pythonGH-7114)
  bpo-34092, test_logging: increase SMTPHandlerTest timeout (pythonGH-8245)
  Simplify __all__ in multiprocessing (pythonGH-6856)
  bpo-34083: Update dict order in Functional HOWTO (pythonGH-8230)
  Doc: Point to Simple statements section instead of PEP (pythonGH-8238)
  bpo-29442: Replace optparse with argparse in setup.py (pythonGH-139)
  bpo-33597: Add What's New for PyGC_Head (pythonGH-8236)
  Dataclasses: Fix example on 30.6.8, add method should receive a list rather than an integer. (pythonGH-8038)
  Fix documentation for input and output tutorial (pythonGH-8231)
  bpo-34009: Expand on platform support changes (pythonGH-8022)
  Factor-out two substantially identical code blocks. (pythonGH-8219)
  bpo-34031: fix incorrect usage of self.fail in two tests (pythonGH-8091)
  ...
zware added a commit to zware/cpython that referenced this pull request Jul 18, 2018
…).

(cherry picked from commit b12112b)

Co-authored-by: Zachary Ware <[email protected]>
@bedevere-bot
Copy link

GH-8334 is a backport of this pull request to the 3.7 branch.

@bedevere-bot
Copy link

GH-8335 is a backport of this pull request to the 3.6 branch.

zware added a commit to zware/cpython that referenced this pull request Jul 18, 2018
…).

(cherry picked from commit b12112b)

Co-authored-by: Zachary Ware <[email protected]>
zware added a commit to zware/cpython that referenced this pull request Jul 18, 2018
…).

(cherry picked from commit b12112b)

Co-authored-by: Zachary Ware <[email protected]>
@bedevere-bot
Copy link

GH-8336 is a backport of this pull request to the 2.7 branch.

zware added a commit that referenced this pull request Jul 20, 2018
zware added a commit that referenced this pull request Jul 20, 2018
zware added a commit that referenced this pull request Jul 20, 2018
CuriousLearner added a commit to CuriousLearner/cpython that referenced this pull request Jul 21, 2018
…ssue-33014

* 'master' of github.com:CuriousLearner/cpython: (722 commits)
  bpo-34087: Fix buffer overflow in int(s) and similar functions (pythonGH-8274)
  bpo-34108: Fix double carriage return in 2to3 on Windows (python#8271)
  bpo-4260: Document that ctypes.xFUNCTYPE are decorators (pythonGH-7924)
  bpo-33723: Fix test_time.test_thread_time() (pythonGH-8267)
  bpo-33967: Remove use of deprecated assertRaisesRegexp() (pythonGH-8261)
  bpo-34080: Fix a memory leak in the compiler. (pythonGH-8222)
  Enable GUI testing on Travis Linux builds via Xvfb (pythonGH-7887)
  bpo-23927: Make getargs.c skipitem() skipping 'w*'. (pythonGH-8192)
  bpo-33648: Remove PY_WARN_ON_C_LOCALE (pythonGH-7114)
  bpo-34092, test_logging: increase SMTPHandlerTest timeout (pythonGH-8245)
  Simplify __all__ in multiprocessing (pythonGH-6856)
  bpo-34083: Update dict order in Functional HOWTO (pythonGH-8230)
  Doc: Point to Simple statements section instead of PEP (pythonGH-8238)
  bpo-29442: Replace optparse with argparse in setup.py (pythonGH-139)
  bpo-33597: Add What's New for PyGC_Head (pythonGH-8236)
  Dataclasses: Fix example on 30.6.8, add method should receive a list rather than an integer. (pythonGH-8038)
  Fix documentation for input and output tutorial (pythonGH-8231)
  bpo-34009: Expand on platform support changes (pythonGH-8022)
  Factor-out two substantially identical code blocks. (pythonGH-8219)
  bpo-34031: fix incorrect usage of self.fail in two tests (pythonGH-8091)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip issue skip news tests Tests in the Lib/test dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants