Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(914)

Unified Diff: tools/telemetry/telemetry/internal/util/find_dependencies_unittest.py

Issue 1467143006: [Telemetry] Migrate find_dependencies internals to tools/perf (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address Ned's comment Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/telemetry/telemetry/internal/util/find_dependencies_unittest.py
diff --git a/tools/telemetry/telemetry/internal/util/find_dependencies_unittest.py b/tools/telemetry/telemetry/internal/util/find_dependencies_unittest.py
deleted file mode 100644
index 7d43915e042c00021da0a414770a870764ec1781..0000000000000000000000000000000000000000
--- a/tools/telemetry/telemetry/internal/util/find_dependencies_unittest.py
+++ /dev/null
@@ -1,38 +0,0 @@
-# Copyright 2014 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.
-
-import os
-import unittest
-
-from telemetry.core import util
-from telemetry.internal.util import find_dependencies
-
-
-class FindDependenciesTest(unittest.TestCase):
- def testFindPythonDependencies(self):
- dog_object_path = os.path.join(
- util.GetUnittestDataDir(),
- 'dependency_test_dir', 'dog', 'dog', 'dog_object.py')
- cat_module_path = os.path.join(
- util.GetUnittestDataDir(),
- 'dependency_test_dir', 'other_animals', 'cat', 'cat')
- cat_module_init_path = os.path.join(cat_module_path, '__init__.py')
- cat_object_path = os.path.join(cat_module_path, 'cat_object.py')
- self.assertEquals(
- set(p for p in find_dependencies.FindPythonDependencies(dog_object_path)),
- {dog_object_path, cat_module_path, cat_module_init_path, cat_object_path})
-
- def testFindPythonDependenciesWithNestedImport(self):
- moose_module_path = os.path.join(
- util.GetUnittestDataDir(),
- 'dependency_test_dir', 'other_animals', 'moose', 'moose')
- moose_object_path = os.path.join(moose_module_path, 'moose_object.py')
- horn_module_path = os.path.join(moose_module_path, 'horn')
- horn_module_init_path = os.path.join(horn_module_path, '__init__.py')
- horn_object_path = os.path.join(horn_module_path, 'horn_object.py')
- self.assertEquals(
- set(p for p in
- find_dependencies.FindPythonDependencies(moose_object_path)),
- {moose_object_path,
- horn_module_path, horn_module_init_path, horn_object_path})

Powered by Google App Engine
This is Rietveld 408576698