# Copyright (c) 2012 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
{
  'includes': [
    'chrome.isolate',
  ],
  'conditions': [
    ['OS=="linux"', {
      'variables': {
        'command': [
          '../testing/xvfb.py',
          '<(PRODUCT_DIR)',
          '<(PRODUCT_DIR)/browser_tests<(EXECUTABLE_SUFFIX)',
          '--test-launcher-bot-mode',
        ],
        'isolate_dependency_tracked': [
          '../testing/xvfb.py',
          '<(PRODUCT_DIR)/libclearkeycdm.so',
          '<(PRODUCT_DIR)/libclearkeycdmadapter.so',
          '<(PRODUCT_DIR)/libppapi_tests.so',
          '<(PRODUCT_DIR)/xdisplaycheck<(EXECUTABLE_SUFFIX)',
        ],
      },
    }],
    ['OS=="linux" and libpeer_target_type=="loadable_module"', {
      'variables': {
        'isolate_dependency_tracked': [
          '<(PRODUCT_DIR)/lib/libpeerconnection.so',
        ],
      },
    }],
    ['OS=="linux" or OS=="mac"', {
      'variables': {
        'isolate_dependency_tracked': [
          'browser/nacl_host/test/debug_stub_browser_tests.py',
          'browser/nacl_host/test/gdb_rsp.py',
        ],
      },
    }],
    ['OS=="linux" or OS=="mac" or OS=="win"', {
      'variables': {
        'isolate_dependency_tracked': [
          '../media/test/data/90rotation.mp4',
          '../media/test/data/bear-320x240-multitrack.webm',
          '../media/test/data/id3_png_test.mp3',
          '../media/test/data/no_streams.webm',
          '../media/test/data/sfx.ogg',
          '../ppapi/tests/test_case.html',
          '../ppapi/tests/test_page.css',
          '../testing/test_env.py',
          '../third_party/accessibility-audit/axs_testing.js',
          '<(PRODUCT_DIR)/browser_tests<(EXECUTABLE_SUFFIX)',
          '<(PRODUCT_DIR)/peerconnection_server<(EXECUTABLE_SUFFIX)',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_glibc.nmf',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_newlib.nmf',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_pnacl.nmf',
          '<(PRODUCT_DIR)/test_case.html',
          '<(PRODUCT_DIR)/test_case.html.mock-http-headers',
          '<(PRODUCT_DIR)/test_page.css',
          'browser/policy/test/asn1der.py',
          'browser/policy/test/policy_testserver.py',
          'browser/safe_browsing/safe_browsing_testserver.py',
          'common/extensions/docs/examples/apps/calculator/app/controller.js',
          'common/extensions/docs/examples/apps/calculator/app/model.js',
          'common/extensions/docs/examples/apps/calculator/app/view.js',
        ],
        'isolate_dependency_untracked': [
          '../content/test/data/',
          '../net/data/',
          '../net/tools/testserver/',
          '../third_party/WebKit/Tools/Scripts/',
          '../third_party/pyftpdlib/',
          '../third_party/pywebsocket/',
          '../third_party/safe_browsing/',
          '../third_party/simplejson/',
          '../third_party/tlslite/',
          '<(PRODUCT_DIR)/nacl_test_data/',
          '<(PRODUCT_DIR)/pnacl/',
          '<(PRODUCT_DIR)/pseudo_locales/',
          '<(PRODUCT_DIR)/pyproto/',
          '<(PRODUCT_DIR)/test_data/chrome/',
          '<(PRODUCT_DIR)/test_data/ppapi/',
          '<(PRODUCT_DIR)/test_url_loader_data/',
          'common/extensions/docs/examples/apps/calculator/tests/',
          'test/data/',
          'third_party/mock4js/',
        ],
        'read_only': 1,
      },
    }],
    ['OS=="linux" or OS=="win"', {
      'variables': {
        'isolate_dependency_tracked': [
          '<(PRODUCT_DIR)/mock_nacl_gdb<(EXECUTABLE_SUFFIX)',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_glibc_x64.nexe',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_newlib_x64.nexe',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_pnacl_newlib_x64.nexe',
        ],
        'isolate_dependency_untracked': [
          '../third_party/bidichecker/',
          '<(PRODUCT_DIR)/lib64/',
          '<(PRODUCT_DIR)/plugins/',
        ],
      },
    }],
    ['OS=="mac"', {
      'variables': {
        'isolate_dependency_tracked': [
          '<(PRODUCT_DIR)/clearkeycdmadapter.plugin',
          '<(PRODUCT_DIR)/libclearkeycdm.dylib',
          '<(PRODUCT_DIR)/osmesa.so',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_glibc_x32.nexe',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_newlib_x32.nexe',
          '<(PRODUCT_DIR)/ppapi_nacl_tests_pnacl_newlib_x32.nexe',
          '<(PRODUCT_DIR)/ppapi_tests.plugin/Contents/MacOS/ppapi_tests',
        ],
        'isolate_dependency_untracked': [
          '<(PRODUCT_DIR)/lib32/',
          '<(PRODUCT_DIR)/plugins/npapi_test_plugin.plugin/',
          '<(PRODUCT_DIR)/plugins/test_netscape_plugin.plugin/',
        ],
      },
    }],
    ['OS=="mac" or OS=="win"', {
      'variables': {
        'command': [
          '../testing/test_env.py',
          '<(PRODUCT_DIR)/browser_tests<(EXECUTABLE_SUFFIX)',
          '--test-launcher-bot-mode',
        ],
      },
    }],
    ['OS=="win"', {
      'variables': {
        'isolate_dependency_tracked': [
          '../native_client/build/build_nexe.py',
          '<(PRODUCT_DIR)/chrome_elf.dll',
          '<(PRODUCT_DIR)/clearkeycdm.dll',
          '<(PRODUCT_DIR)/clearkeycdmadapter.dll',
          '<(PRODUCT_DIR)/ppapi_tests.dll',
          'tools/build/repack_locales.py',
        ],
        'isolate_dependency_untracked': [
          '../third_party/npapi/npspy/extern/plugin/',
          '../third_party/psyco_win32/psyco/',
        ],
      },
    }],
    ['OS=="win" and libpeer_target_type=="loadable_module"', {
      'variables': {
        'isolate_dependency_tracked': [
          '<(PRODUCT_DIR)/libpeerconnection.dll',
        ],
      },
    }],
    ['chromeos==1', {
      'variables': {
        'isolate_dependency_untracked': [
          '<(PRODUCT_DIR)/chromevox_test_data/',
        ],
      },
    }],
  ],
}