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

Side by Side Diff: appengine/findit/common/test/dependency_test.py

Issue 1950123003: [Findit] Fetch DEPS from buildspec/ instead of trunk for chrome official builds. (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: Update doc string. Created 4 years, 7 months 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 unified diff | Download patch
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import unittest 5 import unittest
6 6
7 from common.dependency import Dependency 7 from common.dependency import Dependency
8 from common.dependency import DependencyRoll 8 from common.dependency import DependencyRoll
9 9
10 10
(...skipping 27 matching lines...) Expand all
38 'deps_file': 'DEPS', 38 'deps_file': 'DEPS',
39 'children': { 39 'children': {
40 } 40 }
41 } 41 }
42 } 42 }
43 } 43 }
44 44
45 sub_dep.SetParent(root_dep) 45 sub_dep.SetParent(root_dep)
46 self.assertEqual(expected_dep_tree_dict, root_dep.ToDict()) 46 self.assertEqual(expected_dep_tree_dict, root_dep.ToDict())
47 47
48 def testDependencyForChromeVersion(self):
49 dep = Dependency(
50 'a/b/', 'https://cr.googlesource.com/cr/b.git', '12b', 'DEPS',
51 deps_repo_url='https://chrome-internal', deps_repo_revision='master')
52
53 self.assertEqual(dep.deps_repo_url, 'https://chrome-internal')
54 self.assertEqual(dep.deps_repo_revision, 'master')
55
48 56
49 class DependencyRollTest(unittest.TestCase): 57 class DependencyRollTest(unittest.TestCase):
50 def testToDict(self): 58 def testToDict(self):
51 dep_roll = DependencyRoll( 59 dep_roll = DependencyRoll(
52 'third_party/dep/', 'https://cr.googlesource.com/cr/dep.git', 60 'third_party/dep/', 'https://cr.googlesource.com/cr/dep.git',
53 'rev1', 'rev2') 61 'rev1', 'rev2')
54 expected_dep_roll_dict = { 62 expected_dep_roll_dict = {
55 'path': 'third_party/dep/', 63 'path': 'third_party/dep/',
56 'repo_url': 'https://cr.googlesource.com/cr/dep.git', 64 'repo_url': 'https://cr.googlesource.com/cr/dep.git',
57 'old_revision': 'rev1', 65 'old_revision': 'rev1',
58 'new_revision': 'rev2', 66 'new_revision': 'rev2',
59 } 67 }
60 68
61 self.assertEqual(expected_dep_roll_dict, dep_roll.ToDict()) 69 self.assertEqual(expected_dep_roll_dict, dep_roll.ToDict())
OLDNEW
« no previous file with comments | « appengine/findit/common/test/chromium_deps_test.py ('k') | appengine/findit/common/test/deps_parser_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698