Skip to content

Commit

Permalink
Add Fedora SIGs gitlab group to bugrefs
Browse files Browse the repository at this point in the history
There's a repo under here we need to reference for Fedora flatpak
issues (the URL used in the tests is a real one we need to ref).

Signed-off-by: Adam Williamson <[email protected]>
  • Loading branch information
AdamWill committed Oct 19, 2023
1 parent c5419ae commit 062d841
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/OpenQA/Utils.pm
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ BEGIN {
jsc => 'https://jira.suse.de/browse/',
pio => 'https://pagure.io/',
ggo => 'https://gitlab.gnome.org/',
gfs => 'https://gitlab.com/fedora/sigs/',
);
%BUGURLS = (
'https://bugzilla.novell.com/show_bug.cgi?id=' => 'bsc',
Expand All @@ -68,6 +69,7 @@ BEGIN {
$BUGREFS{jsc} => 'jsc',
$BUGREFS{pio} => 'pio',
$BUGREFS{ggo} => 'ggo',
$BUGREFS{gfs} => 'gfs',
);

$MARKER_REFS = join('|', keys %BUGREFS);
Expand Down
3 changes: 3 additions & 0 deletions t/16-markdown.t
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,9 @@ subtest 'bugrefs to markdown' => sub {
'right markdown';
is bugref_to_markdown('ggo#GNOME/foo#1234'),
'[ggo#GNOME/foo#1234](https://gitlab.gnome.org/GNOME/foo/issues/1234)', 'right markdown';
is bugref_to_markdown('gfs#flatpak/fedora-flatpaks#26'),
'[gfs#flatpak/fedora-flatpaks#26](https://gitlab.com/fedora/sigs/flatpak/fedora-flatpaks/issues/26)',
'right markdown';
is bugref_to_markdown("boo#9876\n\ntest boo#211\n"),
"[boo#9876](https://bugzilla.opensuse.org/show_bug.cgi?id=9876)\n\n"
. "test [boo#211](https://bugzilla.opensuse.org/show_bug.cgi?id=211)\n",
Expand Down
3 changes: 3 additions & 0 deletions t/16-utils.t
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,9 @@ is href_to_bugref('https://pagure.io/foo/issue/1234'), 'pio#foo#1234', 'pagure.i
is href_to_bugref('https://pagure.io/foo/bar/issue/1234'), 'pio#foo/bar#1234', 'pagure.io (with group) url to bugref';
is href_to_bugref('https://gitlab.gnome.org/GNOME/foo/-/issues/1234'), 'ggo#GNOME/foo#1234',
'GNOME gitlab url to bugref';
is href_to_bugref('https://gitlab.com/fedora/sigs/flatpak/fedora-flatpaks/-/issues/26'),
'gfs#flatpak/fedora-flatpaks#26',
'Fedora SIGs gitlab url to bugref';
is find_bug_number('yast_roleconf-ntp-servers-empty-bsc1114818-20181115.png'), 'bsc1114818',
'find the bug number from the needle name';

Expand Down

0 comments on commit 062d841

Please sign in to comment.