@@ -100,19 +100,27 @@ func TestScanRepositoryCmd_Run(t *testing.T) {
100100 }{
101101 {
102102 testName : "aggregate" ,
103- expectedPackagesInBranch : map [string ][]string {"frogbot-update-npm -dependencies-master" : {"uuid" , "minimist" , "mpath" }},
104- expectedVersionUpdatesInBranch : map [string ][]string {"frogbot-update-npm -dependencies-master" : {"^1.2.6" , "^9.0.0" , "^0.8.4" }},
103+ expectedPackagesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0 -dependencies-master" : {"uuid" , "minimist" , "mpath" }},
104+ expectedVersionUpdatesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0 -dependencies-master" : {"^1.2.6" , "^9.0.0" , "^0.8.4" }},
105105 packageDescriptorPaths : []string {"package.json" },
106106 aggregateFixes : true ,
107107 },
108108 {
109109 testName : "aggregate-multi-dir" ,
110- expectedPackagesInBranch : map [string ][]string {"frogbot-update-npm -dependencies-master" : {"uuid" , "minimatch" , "mpath" , "minimist" }},
111- expectedVersionUpdatesInBranch : map [string ][]string {"frogbot-update-npm -dependencies-master" : {"^1.2.6" , "^9.0.0" , "^0.8.4" , "^3.0.5" }},
112- expectedMissingFilesInBranch : map [string ][]string {"frogbot-update-npm -dependencies-master" : {"npm1/package-lock.json" , "npm2/package-lock.json" }},
110+ expectedPackagesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0 -dependencies-master" : {"uuid" , "minimatch" , "mpath" , "minimist" }},
111+ expectedVersionUpdatesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0 -dependencies-master" : {"^1.2.6" , "^9.0.0" , "^0.8.4" , "^3.0.5" }},
112+ expectedMissingFilesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0 -dependencies-master" : {"npm1/package-lock.json" , "npm2/package-lock.json" }},
113113 packageDescriptorPaths : []string {"npm1/package.json" , "npm2/package.json" },
114114 aggregateFixes : true ,
115115 },
116+ {
117+ testName : "aggregate-multi-project" ,
118+ expectedPackagesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0-dependencies-master" : {"uuid" , "minimatch" , "mpath" }, "frogbot-update-e8fa179873704bb1362147aff9c40040-dependencies-master" : {"pyjwt" , "pexpect" }},
119+ expectedVersionUpdatesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0-dependencies-master" : {"^9.0.0" , "^0.8.4" , "^3.0.5" }, "frogbot-update-e8fa179873704bb1362147aff9c40040-dependencies-master" : {"2.4.0" }},
120+ expectedMissingFilesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0-dependencies-master" : {"npm/package-lock.json" }},
121+ packageDescriptorPaths : []string {"npm/package.json" , "pip/requirements.txt" },
122+ aggregateFixes : true ,
123+ },
116124 {
117125 testName : "aggregate-no-vul" ,
118126 // No branch is being created because there are no vulnerabilities.
@@ -140,8 +148,8 @@ func TestScanRepositoryCmd_Run(t *testing.T) {
140148 {
141149 // This testcase checks the partial results feature. It simulates a failure in the dependency tree construction in the test's project inner module
142150 testName : "partial-results-enabled" ,
143- expectedPackagesInBranch : map [string ][]string {"frogbot-update-npm -dependencies-master" : {"minimist" , "mpath" }},
144- expectedVersionUpdatesInBranch : map [string ][]string {"frogbot-update-npm -dependencies-master" : {"1.2.6" , "0.8.4" }},
151+ expectedPackagesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0 -dependencies-master" : {"minimist" , "mpath" }},
152+ expectedVersionUpdatesInBranch : map [string ][]string {"frogbot-update-68d9dee2475e5986e783d85dfa11baa0 -dependencies-master" : {"1.2.6" , "0.8.4" }},
145153 packageDescriptorPaths : []string {"package.json" , "inner-project/package.json" },
146154 aggregateFixes : true ,
147155 allowPartialResults : true ,
0 commit comments