Changeset 161214 in webkit


Ignore:
Timestamp:
Jan 2, 2014 11:45:58 AM (10 years ago)
Author:
Martin Robinson
Message:

[GTK] [CMake] run-gtk-tests should run with the cmake build
https://bugs.webkit.org/show_bug.cgi?id=126341

Reviewed by Carlos Garcia Campos.

  • Scripts/run-gtk-tests:

(TestRunner.init): Use the new calling conventions for the common script.
(TestRunner._setup_testing_environment): Ditto.

  • gtk/common.py:

(set_build_types): Added set_build_types, to avoid having build_type arguments
for all functions in common.
(binary_build_path): Added this function which gets the path to the built binaries.
(get_build_path): Removed the build_types argument.
(build_path): Removed the build_types argument and call get_build_path directly now.

Location:
trunk/Tools
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r161213 r161214  
     12014-01-02  Martin Robinson  <mrobinson@igalia.com>
     2
     3        [GTK] [CMake] run-gtk-tests should run with the cmake build
     4        https://bugs.webkit.org/show_bug.cgi?id=126341
     5
     6        Reviewed by Carlos Garcia Campos.
     7
     8        * Scripts/run-gtk-tests:
     9        (TestRunner.__init__): Use the new calling conventions for the common script.
     10        (TestRunner._setup_testing_environment): Ditto.
     11        * gtk/common.py:
     12        (set_build_types): Added set_build_types, to avoid having build_type arguments
     13        for all functions in common.
     14        (binary_build_path): Added this function which gets the path to the built binaries.
     15        (get_build_path): Removed the build_types argument.
     16        (build_path): Removed the build_types argument and call get_build_path directly now.
     17
    1182014-01-02  Alexey Proskuryakov  <ap@apple.com>
    219
  • trunk/Tools/Scripts/run-gtk-tests

    r161182 r161214  
    9292    def __init__(self, options, tests=[]):
    9393        self._options = options
     94
    9495        self._build_type = "Debug" if self._options.debug else "Release"
    95 
    96         self._programs_path = common.build_path_for_build_types((self._build_type,), "Programs")
     96        common.set_build_types((self._build_type,))
     97
     98        self._programs_path = common.binary_build_path()
    9799        self._tests = self._get_tests(tests)
    98100        self._skipped_tests = TestRunner.SKIPPED
     
    195197        self._test_env['GSETTINGS_BACKEND'] = 'memory'
    196198        self._test_env["TEST_WEBKIT_API_WEBKIT2_RESOURCES_PATH"] = common.top_level_path("Tools", "TestWebKitAPI", "Tests", "WebKit2")
    197         self._test_env["TEST_WEBKIT_API_WEBKIT2_INJECTED_BUNDLE_PATH"] = common.build_path_for_build_types((self._build_type,), "Libraries")
     199        self._test_env["TEST_WEBKIT_API_WEBKIT2_INJECTED_BUNDLE_PATH"] = common.library_build_path()
    198200        self._test_env["WEBKIT_EXEC_PATH"] = self._programs_path
    199201
  • trunk/Tools/gtk/common.py

    r161023 r161214  
    2626library_build_dir = None
    2727is_cmake = None
     28build_types = ('Release', 'Debug')
     29
     30
     31def set_build_types(new_build_types):
     32    global build_types
     33    build_types = new_build_types
    2834
    2935
     
    4551
    4652
     53def binary_build_path(*args):
     54    global library_build_dir
     55    if not library_build_dir:
     56        if is_cmake_build():
     57            library_build_dir = build_path('bin', *args)
     58        else:
     59            library_build_dir = build_path('Programs', *args)
     60    return library_build_dir
     61
     62
    4763def script_path(*args):
    4864    global script_dir
     
    5672
    5773
    58 def get_build_path(build_types=('Release', 'Debug'), fatal=True):
     74def get_build_path(fatal=True):
    5975    global build_dir
    6076    if build_dir:
     
    8197        return build_dir
    8298
     99    global build_types
    83100    for build_type in build_types:
    84101        build_dir = top_level_path('WebKitBuild', build_type)
     
    104121
    105122
    106 def build_path_for_build_types(build_types, *args):
    107     return os.path.join(*(get_build_path(build_types),) + args)
    108 
    109 
    110123def build_path(*args):
    111     return build_path_for_build_types(('Release', 'Debug'), *args)
     124    return os.path.join(*(get_build_path(),) + args)
    112125
    113126
Note: See TracChangeset for help on using the changeset viewer.