diff --git a/.travis.yml b/.travis.yml index 6c6738449..2e4b51713 100644 --- a/.travis.yml +++ b/.travis.yml @@ -20,15 +20,13 @@ addons: env: global: - - INSTALL_EDM_VERSION=2.0.0 + - INSTALL_EDM_VERSION=3.0.1 PYTHONUNBUFFERED="1" matrix: include: - - env: RUNTIME=3.5 TOOLKITS="null pyqt pyqt5" PILLOW='pillow' - env: RUNTIME=3.6 TOOLKITS="null pyqt pyqt5" PILLOW='pillow' - env: RUNTIME=3.6 TOOLKITS="wx" PILLOW='pillow' - - env: RUNTIME=3.5 TOOLKITS=null PILLOW='pillow<3.0.0' - env: RUNTIME=3.6 TOOLKITS=null PILLOW='pillow<3.0.0' allow_failures: - env: RUNTIME=3.6 TOOLKITS="wx" PILLOW='pillow' diff --git a/appveyor.yml b/appveyor.yml index e0ff6139f..1f789c36c 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -5,11 +5,9 @@ environment: global: PYTHONUNBUFFERED: "1" - INSTALL_EDM_VERSION: "2.0.0" + INSTALL_EDM_VERSION: "3.0.1" matrix: - - RUNTIME: '3.5' - TOOLKITS: "null pyqt pyqt5" - RUNTIME: '3.6' TOOLKITS: "null pyqt pyqt5" - RUNTIME: '3.6' diff --git a/ci/edmtool.py b/ci/edmtool.py index c0223d3b2..b1c7778f2 100644 --- a/ci/edmtool.py +++ b/ci/edmtool.py @@ -89,11 +89,11 @@ import click supported_combinations = { - '3.5': {'pyqt', 'pyqt5', 'null'}, '3.6': {'pyqt', 'pyqt5', 'null'}, } dependencies = { + "apptools", "six", "nose", "mock", @@ -102,13 +102,14 @@ "pygments", "pyparsing", "swig", - "unittest2", + "traits", + # Avoiding traitsui 7.1.0 for now due to private imports + # in test suite (see enthought/enable#425) + "traitsui==7.0.1-1", + "pyface==7.0.1-1", "pypdf2", "swig", - # required by some demos - "chaco", - "mayavi", - "scipy", + "unittest2", } extra_dependencies = { @@ -135,6 +136,10 @@ dependencies.add('Cython') +#: Path to the top-level source directory +ROOT = os.path.abspath(os.path.join(os.path.dirname(__file__), "..")) + + @click.group() def cli(): pass @@ -158,14 +163,19 @@ def install(runtime, toolkit, pillow, environment): "edm install -y -e {environment} {packages}", "edm run -e {environment} -- pip install {pillow}", ("edm run -e {environment} -- pip install -r ci/requirements.txt" - " --no-dependencies --ignore-installed"), + " --no-dependencies"), ] # pip install pyqt5, because we don't have it in EDM yet if toolkit == 'pyqt5': commands.append("edm run -e {environment} -- pip install pyqt5==5.9.2") - commands.append("edm run -e {environment} -- python setup.py install") + # No matter happens before, always install local source again or + # we risk testing against an released enable. + commands.append( + "edm run -e {environment} -- " + "pip install --force-reinstall --no-dependencies " + ROOT + ) click.echo("Creating environment '{environment}'".format(**parameters)) execute(commands, parameters) diff --git a/ci/requirements.txt b/ci/requirements.txt index fb94103ba..320ea930f 100644 --- a/ci/requirements.txt +++ b/ci/requirements.txt @@ -4,7 +4,3 @@ fonttools==3.28.0 reportlab<=3.1 kiwisolver ; python_version <= "2.7" https://bitbucket.org/pyglet/pyglet/get/pyglet-1.1.4.zip ; python_version <= "2.7" -git+http://github.com/enthought/traits.git#egg=traits -git+http://github.com/enthought/pyface.git#egg=pyface -git+http://github.com/enthought/traitsui.git#egg=traitsui[demo] -git+http://github.com/enthought/apptools.git#egg=apptools diff --git a/enable/tests/container_test_case.py b/enable/tests/container_test_case.py index b35a17b96..a43afb5aa 100644 --- a/enable/tests/container_test_case.py +++ b/enable/tests/container_test_case.py @@ -39,7 +39,7 @@ def test_get_set_components(self): # Exercise set_components: new_list = [self.c1, self.c3] container.components = new_list - self.assertIs(container.components, new_list) + self.assertEqual(container.components, new_list) def test_add_remove(self): container = self.create_simple_components() diff --git a/enable/tests/tools/hover_tool_test_case.py b/enable/tests/tools/hover_tool_test_case.py index 1243f4ee2..9bb6b5ce6 100644 --- a/enable/tests/tools/hover_tool_test_case.py +++ b/enable/tests/tools/hover_tool_test_case.py @@ -19,6 +19,13 @@ GuiTestAssistant = toolkit_object('util.gui_test_assistant:GuiTestAssistant') +if GuiTestAssistant.__name__ == "Unimplemented": + + # ensure null toolkit has an inheritable GuiTestAssistant + # Note that without this definition, the test caseĀ fails as soon as it + # is instantiated, before it can be skipped. + class GuiTestAssistant(object): + pass LOWER_BOUND = 50