mirror of https://github.com/kivy/kivy.git
Removed debug print, oops.
This commit is contained in:
parent
68fca301f9
commit
c3251144f0
|
@ -5,9 +5,9 @@ utils tests
|
||||||
|
|
||||||
import os, unittest
|
import os, unittest
|
||||||
try:
|
try:
|
||||||
from unittest.mock import MagicMock, patch, PropertyMock # python 3
|
from unittest.mock import patch # python 3.x
|
||||||
except:
|
except:
|
||||||
from mock import MagicMock, patch, PropertyMock
|
from mock import patch # python 2.x
|
||||||
|
|
||||||
from kivy.utils import (boundary, escape_markup, format_bytes_to_human,
|
from kivy.utils import (boundary, escape_markup, format_bytes_to_human,
|
||||||
is_color_transparent, SafeList, get_random_color, get_hex_from_color,
|
is_color_transparent, SafeList, get_random_color, get_hex_from_color,
|
||||||
|
@ -151,10 +151,11 @@ class UtilsTest(unittest.TestCase):
|
||||||
self.assertEqual(p, [x[i], y[i]])
|
self.assertEqual(p, [x[i], y[i]])
|
||||||
|
|
||||||
def test_Platform(self):
|
def test_Platform(self):
|
||||||
pf = Platform() #
|
# Those calls do not have specific intent, no assertions
|
||||||
print pf() # __call__ deprecated
|
pf = Platform()
|
||||||
print hash(pf)
|
pf() # __call__ deprecated
|
||||||
print repr(pf)
|
hash(pf)
|
||||||
|
repr(pf)
|
||||||
|
|
||||||
def test_Platform_android(self):
|
def test_Platform_android(self):
|
||||||
with patch.dict('os.environ', {'ANDROID_ARGUMENT': ''}):
|
with patch.dict('os.environ', {'ANDROID_ARGUMENT': ''}):
|
||||||
|
|
|
@ -275,7 +275,6 @@ class Platform(object):
|
||||||
if self._platform_ios is None:
|
if self._platform_ios is None:
|
||||||
self._platform_ios = (environ.get('KIVY_BUILD', '') == 'ios')
|
self._platform_ios = (environ.get('KIVY_BUILD', '') == 'ios')
|
||||||
|
|
||||||
print _sys_platform, str(_sys_platform), _sys_platform[:5], _sys_platform == 'darwin'
|
|
||||||
# On android, _sys_platform return 'linux2', so prefer to check the
|
# On android, _sys_platform return 'linux2', so prefer to check the
|
||||||
# import of Android module than trying to rely on _sys_platform.
|
# import of Android module than trying to rely on _sys_platform.
|
||||||
if self._platform_android is True:
|
if self._platform_android is True:
|
||||||
|
|
Loading…
Reference in New Issue