On 10.01.2024 16:45, Lukas Funke wrote:
On 10.01.2024 14:59, Richard Purdie wrote:
On Wed, 2024-01-10 at 12:53 +0100, Vyacheslav Yurkov wrote:
Local modules are usually referenced with a 'replace' directive in
go.mod file. If that's the case, remove them from populating SRC_URI.

Signed-off-by: Vyacheslav Yurkov <uvv.m...@gmail.com>
---
  scripts/lib/recipetool/create_go.py | 32 +++++++++++++++++------------
  1 file changed, 19 insertions(+), 13 deletions(-)

Do these changes mean we need to improve the test coverage in oe-
selftest for recipetool?

Test converage needs improvement, yes. I haven't considered the case for local modules since this seems to be rare(?). Are there public projects which use this mechanism?

Best regards
Lukas


I added coverage for local modules in my v2.

I'm not a golang expert, but it seems that local modules in golang is a means to "place a patched version into the project space until upstream fixes it" more or less like Yocto does with Upstream patches. It's used a lot by in-house projects, but you could also get a glimpse on github with this query https://github.com/search?q=path%3A%2Fgo.mod+NOT+is%3Afork+content%3A%2F%5Ereplace+.*%2F&type=code&query=content%3Ago.mod+replace&p=3 . Note, Github is able to display only first 100 search results (Github API restriction).

One thing I don't like in my v2 is that I need to look up a public project to add required coverage. I would rather improve tests further by having everything in one repository and just one test, i.e. it has to be a small test project that could be used to test all go-related functionality. The question is though where it should be placed? I could create it on my Github account, but would that be a good option?

Richard, any suggestions on where these projects for selftest coverage should be hosted?

Slava
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#193836): 
https://lists.openembedded.org/g/openembedded-core/message/193836
Mute This Topic: https://lists.openembedded.org/mt/103639058/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to