From 57f9be568adb6ac827067d312a4cc709ddf126ef Mon Sep 17 00:00:00 2001 From: Paul Nasrat Date: Sun, 29 Jul 2012 10:40:14 +0100 Subject: [PATCH] Issue #557 fix test failing on windows. More path equality fun, use normpath to ensure path sep correct. --- tests/test_uninstall.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_uninstall.py b/tests/test_uninstall.py index 3a0fac92c..408847487 100644 --- a/tests/test_uninstall.py +++ b/tests/test_uninstall.py @@ -1,6 +1,6 @@ import textwrap import sys -from os.path import join, abspath +from os.path import join, abspath, normpath from tempfile import mkdtemp from mock import Mock from nose.tools import assert_raises @@ -65,10 +65,10 @@ def test_uninstall_overlapping_package(): assert join(env.site_packages, 'parent') in result1.files_created, sorted(result1.files_created.keys()) result2 = run_pip('install', child_pkg, expect_error=False) assert join(env.site_packages, 'child') in result2.files_created, sorted(result2.files_created.keys()) - assert join(env.site_packages, 'parent/plugins/child_plugin.py') in result2.files_created, sorted(result2.files_created.keys()) + assert normpath(join(env.site_packages, 'parent/plugins/child_plugin.py')) in result2.files_created, sorted(result2.files_created.keys()) result3 = run_pip('uninstall', '-y', 'child', expect_error=False) assert join(env.site_packages, 'child') in result3.files_deleted, sorted(result3.files_created.keys()) - assert join(env.site_packages, 'parent/plugins/child_plugin.py') in result3.files_deleted, sorted(result3.files_deleted.keys()) + assert normpath(join(env.site_packages, 'parent/plugins/child_plugin.py')) in result3.files_deleted, sorted(result3.files_deleted.keys()) assert join(env.site_packages, 'parent') not in result3.files_deleted, sorted(result3.files_deleted.keys()) # Additional check: uninstalling 'child' should return things to the # previous state, without unintended side effects.