fix(scan): parse error on SUSE #515 (#786)

This commit is contained in:
Kota Kanbe
2019-03-12 17:36:27 +09:00
committed by GitHub
parent 5c6e06b05e
commit 53dd90302e
2 changed files with 13 additions and 6 deletions

View File

@@ -30,7 +30,8 @@ func TestScanUpdatablePackages(t *testing.T) {
stdout := `S | Repository | Name | Current Version | Available Version | Arch
--+---------------------------------------------+-------------------------------+-----------------------------+-----------------------------+-------
v | SLES12-SP2-Updates | SUSEConnect | 0.3.0-19.8.1 | 0.3.1-19.11.2 | x86_64
v | SLES12-SP2-Updates | SuSEfirewall2 | 3.6.312-2.3.1 | 3.6.312-2.10.1 | noarch`
v | SLES12-SP2-Updates | SuSEfirewall2 | 3.6.312-2.3.1 | 3.6.312-2.10.1 | noarch
v | Clone of SLES11-SP3-Updates for x86_64 | ConsoleKit | 0.2.10-64.65.1 | 0.2.10-64.69.1 | x86_64`
var tests = []struct {
in string
@@ -51,6 +52,12 @@ v | SLES12-SP2-Updates | SuSEfirewall2
NewRelease: "2.10.1",
Arch: "noarch",
},
models.Package{
Name: "ConsoleKit",
NewVersion: "0.2.10",
NewRelease: "64.69.1",
Arch: "x86_64",
},
),
},
}