47
47
def testGet_extra_config(self):
48
extra_config = self.i.get_extra_config({"project": "a",
48
extra_config = self.i.get_extra_config({"project": "a1/a2",
49
49
"currentPatchSet": {"ref": "b"}})
50
self.assertEquals("CONFIGURATION='%s && %s && %s && %s'" % (
52
"git fetch http://%s/p/%s %s" % (self.i.gc.review_host, "a", "b"),
53
"git checkout FETCH_HEAD",
54
"cd -"), extra_config)
50
self.assert_(0 < extra_config.find(
51
"CONFIGURATION='%s && %s && %s && %s'" % (
52
"cd $(repo list | sed '/a1\/a2/ ! d; s/^\(\w*\).*/\1/')",
53
"git fetch http://%s/p/%s %s" % (
54
self.i.gc.review_host, "a1/a2", "b"),
55
"git checkout FETCH_HEAD",
55
57
extra_config = self.i.get_extra_config({"project": "platform/manifest",
56
58
"currentPatchSet": {"ref": "b"}})
57
self.assertEquals("CONFIGURATION='%s && %s && %s && %s && %s && %s && %s'" % (
60
"git fetch http://%s/p/%s %s" % (self.i.gc.review_host,
61
"platform/manifest", "b"),
62
"git checkout -b build FETCH_HEAD",
64
"repo init -u .repo/manifests -b build",
65
"repo sync -ld"), extra_config)
59
self.assert_(0 < extra_config.find(
60
"CONFIGURATION='%s && %s && %s && %s && %s && %s && %s'" % (
63
"git fetch http://%s/p/%s %s" % (self.i.gc.review_host,
64
"platform/manifest", "b"),
65
"git checkout -b build FETCH_HEAD",
67
"repo init -u .repo/manifests -b build",
68
71
def xtestBuild_jobs(self):