From: Olof Johansson <olof.johansson@axis.com>
To: Richard Purdie <richard.purdie@linuxfoundation.org>
Cc: bitbake-devel <bitbake-devel@lists.openembedded.org>
Subject: Re: [PATCH] fetch/git: Change to use clearer ssh url syntax for broken servers
Date: Fri, 15 Jan 2016 17:18:53 +0100 [thread overview]
Message-ID: <20160115161852.GI31212@axis.com> (raw)
In-Reply-To: <1452870294.28375.167.camel@linuxfoundation.org>
On 16-01-15 15:04 +0000, Richard Purdie wrote:
> I have also double checked this and I agree, the bitbucket servers do
> now seem to work as you'd expect.
>
> I swear I had problems originally but I can't figure out what those
> were so I will revert the patch.
Thanks!
> My point about improving the selftests if there are url formats you
> depend upon stands though.
While I'm happy to contribute such a change, I'm not fond of the
structure of the bitbake tests. They are a lot of times system
tests that require access to remote servers etc.
And in this case, the manipulation happens in the git fetcher,
and it has no unit tests at all (not including indirect system
testing). E.g., the following trivial patch to the URLHandle
tests would not catch this issue:
--- a/bitbake/lib/bb/tests/fetch.py
+++ b/bitbake/lib/bb/tests/fetch.py
@@ -644,7 +644,8 @@ class URLHandle(unittest.TestCase):
...
- "git://git.openembedded.org/bitbake;branch=@foo" : ('git', 'git.openembedded.org', '/bitbake', '', '', {'branch': '@foo'})
+ "git://git.openembedded.org/bitbake;branch=@foo" : ('git', 'git.openembedded.org', '/bitbake', '', '', {'branch': '@foo'}),
+ "git://git.example.org:1234/bitbake" : ('git', 'git.example.org:1234', '/bitbake', '', '', {}),
...
I did try to add unittests for the git fetcher at one point, but
the patches were rejected because I made changes to the git
fetcher itself, in order to simplify testing. In this case, the
behavior is isolated to _get_repo_url, which is side effect free,
so again, I'm happy to try adding tests for this particular case.
Could also mention that the bb.fetch2.URI class' unittest suite
does have tests for various variations, including port numbers,
and it was designed to be side-effect free in order to make unit
testing simple. Adapting this would give some testing for free.
Anyways, I'll hopefully have a patch ready for review early next
week. Have a nice weekend :)
--
olofjn
prev parent reply other threads:[~2016-01-15 16:18 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-07 13:18 [PATCH] fetch/git: Change to use clearer ssh url syntax for broken servers Richard Purdie
2016-01-13 21:37 ` Andre McCurdy
2016-01-13 22:19 ` Richard Purdie
2016-01-13 23:20 ` Andre McCurdy
2016-01-13 23:59 ` Andre McCurdy
2016-01-14 14:47 ` Peter Kjellerstedt
2016-01-14 15:25 ` Richard Purdie
2016-01-14 16:51 ` Andre McCurdy
2016-01-14 17:07 ` Olof Johansson
2016-01-14 17:50 ` Peter Kjellerstedt
2016-01-15 15:04 ` Richard Purdie
2016-01-15 16:18 ` Olof Johansson [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160115161852.GI31212@axis.com \
--to=olof.johansson@axis.com \
--cc=bitbake-devel@lists.openembedded.org \
--cc=richard.purdie@linuxfoundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.