~mvo/software-center/set-ssl-stuff-in-webkitwidget

« back to all changes in this revision

Viewing changes to tests/test_utils.py

  • Committer: Michael Vogt
  • Date: 2012-07-19 09:29:16 UTC
  • mfrom: (2989.33.20 5.2)
  • Revision ID: michael.vogt@ubuntu.com-20120719092916-dei4mt5hhyxkqm23
merged from the 5.2 branch, resolve conflicts (many :/) and fix failing tests in test_unity_launcher_integration via setUpClass and updates to the DesktopFilepathConversionTestCase bits to use os.path.join()

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
 
16
16
from tests.utils import (
17
17
    do_events,
 
18
    get_test_gtk3_icon_cache,
18
19
    setup_test_env,
19
20
    UTILS_DIR,
20
21
)
26
27
    clear_token_from_ubuntu_sso_sync,
27
28
    decode_xml_char_reference,
28
29
    ensure_file_writable_and_delete_if_not,
 
30
    get_file_path_from_iconname,
29
31
    get_http_proxy_string_from_libproxy,
30
32
    get_http_proxy_string_from_gsettings,
31
33
    get_nice_date_string,
221
223
        # cleanup
222
224
        shutil.rmtree(tmp)
223
225
 
 
226
    def test_get_file_path_from_iconname(self):
 
227
        icons = get_test_gtk3_icon_cache()
 
228
        icon_path = get_file_path_from_iconname(
 
229
                icons,
 
230
                "softwarecenter")
 
231
        self.assertEqual(
 
232
                icon_path,
 
233
                "/usr/share/icons/hicolor/48x48/apps/softwarecenter.svg")
 
234
 
224
235
 
225
236
class TestExpungeCache(unittest.TestCase):
226
237