<feed xmlns='http://www.w3.org/2005/Atom'>
<title>tools/git-repo.git/tests/test_project.py, branch v2.18</title>
<subtitle>Mirror of gerrit.googlesource.com/git-repo</subtitle>
<id>https://git.enea.com/cgit/tools/git-repo.git/atom?h=v2.18</id>
<link rel='self' href='https://git.enea.com/cgit/tools/git-repo.git/atom?h=v2.18'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/'/>
<updated>2021-04-14T16:22:52+00:00</updated>
<entry>
<title>tests: Make ReviewableBranchTests.test_smoke work with git &lt; 2.28.0</title>
<updated>2021-04-14T16:22:52+00:00</updated>
<author>
<name>Peter Kjellerstedt</name>
<email>pkj@axis.com</email>
</author>
<published>2021-04-12T21:25:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=b8bf291ddbe00731d441a34cbf1ec5b5f95f401b'/>
<id>urn:sha1:b8bf291ddbe00731d441a34cbf1ec5b5f95f401b</id>
<content type='text'>
Bug: https://crbug.com/gerrit/14380
Change-Id: Id015bd98b008e1530ada2c7e4332c67e8e208e25
Signed-off-by: Peter Kjellerstedt &lt;peter.kjellerstedt@axis.com&gt;
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/303325
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>strip python2-only coding:utf-8 &amp; print_function settings</title>
<updated>2021-01-06T18:53:05+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2021-01-01T13:42:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=784ccfc040dc8efa1a64d3c7d4070b66beb15d08'/>
<id>urn:sha1:784ccfc040dc8efa1a64d3c7d4070b66beb15d08</id>
<content type='text'>
We're committed to Python 3 at this point, so clean up boilerplate.

Bug: https://crbug.com/gerrit/10418
Change-Id: Ib1719ba2eb65c53b94881a1a1bf203ddfcaaafed
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/292382
Reviewed-by: Chris Mcdonald &lt;cjmcdonald@google.com&gt;
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>Fix tests after "use new main branch"</title>
<updated>2020-12-03T07:29:59+00:00</updated>
<author>
<name>Fredrik de Groot</name>
<email>fredrik.de.groot@volvocars.com</email>
</author>
<published>2020-12-01T14:58:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=6342d5691478873708ee9363bd7dc8e275a75098'/>
<id>urn:sha1:6342d5691478873708ee9363bd7dc8e275a75098</id>
<content type='text'>
Tests worked fine if init.defaultBranch main was used,
but failed due to git branch reasons if master was still used.

Since we can only use init.defaultBranch if git version &gt;= 2.28,
I also went with a template dir HEAD main tweak if lower so tests
now pass regardless of client git default branch and version.

Test: Ran tests with ~/.gitconfig:init.defaultBranch=master
Test: Ran tests with ~/.gitconfig:init.defaultBranch=main
Test: Ran tests for both code branches of git require

Change-Id: I49fa1e4ae45b8aec16a093132ee9fa466cbc11ec
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/290404
Tested-by: Fredrik de Groot &lt;fredrik.de.groot@volvocars.com&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>tests: use new main branch</title>
<updated>2020-11-17T04:29:09+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2020-11-17T03:56:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=e283b95cf2c95befcb2b67259fd8877c1c36d25e'/>
<id>urn:sha1:e283b95cf2c95befcb2b67259fd8877c1c36d25e</id>
<content type='text'>
Now that we clone "main" by default, use that for our local test.

Change-Id: Ib8420074bdfabfcb9d5252a3a0ecd3d852ca36e8
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/288422
Reviewed-by: Jonathan Nieder &lt;jrn@google.com&gt;
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>Move RepoHook class from project.py file to dedicated file</title>
<updated>2020-11-03T22:08:08+00:00</updated>
<author>
<name>Remy Bohmer</name>
<email>github@bohmer.net</email>
</author>
<published>2020-09-10T08:38:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=16c1328fecdbd950bb4f2c24f9c49a8ed0992c50'/>
<id>urn:sha1:16c1328fecdbd950bb4f2c24f9c49a8ed0992c50</id>
<content type='text'>
The project.py file is huge and contains multiple
classes. By moving it to seperate class files the code
becomes more readable and maintainable.

Signed-off-by: Remy Bohmer &lt;github@bohmer.net&gt;
Change-Id: Ida9d99d31751d627ae1ea0373418080696d2e14b
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/281293
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: Remy Bohmer &lt;linux@bohmer.net&gt;
</content>
</entry>
<entry>
<title>manifest/tests: get them passing under Windows</title>
<updated>2020-02-21T05:17:05+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2020-02-20T03:36:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=d9254599f9bb47632313ecb90c5f281ceca5da3a'/>
<id>urn:sha1:d9254599f9bb47632313ecb90c5f281ceca5da3a</id>
<content type='text'>
We also need to check more things in the manifest/project handlers,
and use platform_utils in a few places to address Windows behavior.

Drop Python 2.7 from Windows testing as it definitely doesn't work
and we won't be fixing it.

Change-Id: I83d00ee9f1612312bb3f7147cb9535fc61268245
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/256113
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
Reviewed-by: Jonathan Nieder &lt;jrn@google.com&gt;
Reviewed-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
</content>
</entry>
<entry>
<title>test_project.py: Remove unused variable in 'with' statement</title>
<updated>2020-02-12T02:56:32+00:00</updated>
<author>
<name>David Pursehouse</name>
<email>dpursehouse@collab.net</email>
</author>
<published>2020-02-12T02:36:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=348e218d5b85dc1f497e43a8822ecc8ab73df65e'/>
<id>urn:sha1:348e218d5b85dc1f497e43a8822ecc8ab73df65e</id>
<content type='text'>
flake8 reports:

 F841 local variable 'f' is assigned to but never used

Change-Id: If808eb381ee44c7da71e6281615a06a6723cf945
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/254593
Tested-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>Fix duplicate method name in test_project.py</title>
<updated>2020-02-12T02:55:51+00:00</updated>
<author>
<name>David Pursehouse</name>
<email>dpursehouse@collab.net</email>
</author>
<published>2020-02-12T02:14:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=4bbba7d627d9d801f9e3ab50a864a0d2b70bb3e7'/>
<id>urn:sha1:4bbba7d627d9d801f9e3ab50a864a0d2b70bb3e7</id>
<content type='text'>
flake8 reports:

  F811 redefinition of unused 'test_src_block_dir' from line 259

which is caused by having two methods with the same name. Rename
them both to better desribe their purpose.

Change-Id: If7612a42001776d71bb1a6a80fc631d3d262e6ce
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/254449
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
</content>
</entry>
<entry>
<title>project: allow src=. with symlinks</title>
<updated>2020-02-11T04:23:26+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2020-02-11T02:35:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=07392ed32662006c029299bc06617310cfe17957'/>
<id>urn:sha1:07392ed32662006c029299bc06617310cfe17957</id>
<content type='text'>
Some Android/Nest manifests are using &lt;linkfile&gt; with src="." to
create stable paths to specific projects.  Allow that specific
use case as it seems reasonable to support.

Bug: https://crbug.com/gerrit/11218
Change-Id: I16dbe8d9fe42ea45440afcb61404c753bff1930d
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/254330
Reviewed-by: Chanho Park &lt;parkch98@gmail.com&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>project: add basic path checks for &lt;copyfile&gt; &amp; &lt;linkfile&gt;</title>
<updated>2020-02-04T20:34:23+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2019-08-02T19:57:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=e6a202f790daaf204513b8c53b824fcc246f9972'/>
<id>urn:sha1:e6a202f790daaf204513b8c53b824fcc246f9972</id>
<content type='text'>
Reject paths in &lt;copyfile&gt; &amp; &lt;linkfile&gt; that try to use symlinks or
non-file or non-dirs.

We don't fully validate &lt;linkfile&gt; when src is a glob as it's a bit
complicated -- any component in the src could be the glob.  We make
sure the destination is a directory, and that any paths in that dir
are created as symlinks.  So while this can be used to read any path,
it can't be abused to write to any paths.

Bug: https://crbug.com/gerrit/11218
Change-Id: I68b6d789b5ca4e43f569e75e8b293b3e13d3224b
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/233074
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Reviewed-by: Michael Mortensen &lt;mmortensen@google.com&gt;
</content>
</entry>
</feed>
