[agent-go] - image sync entity
This commit is contained in:
@@ -11,7 +11,7 @@ import (
|
||||
|
||||
func TestFetchDependencyRepos_Middle(t *testing.T) {
|
||||
|
||||
errorPullImageList, errorGzipImageList, realCmiiImageName, allGzipFileNameList := DownloadCompressUploadDependency(true, true, false, false)
|
||||
errorPullImageList, errorGzipImageList, realCmiiImageName, allGzipFileNameList := C_DownloadCompressUploadDependency(true, true, false, false)
|
||||
|
||||
utils.BeautifulPrintListWithTitle(errorPullImageList, "errorPullImageList")
|
||||
utils.BeautifulPrintListWithTitle(errorGzipImageList, "errorGzipImageList")
|
||||
@@ -22,7 +22,7 @@ func TestFetchDependencyRepos_Middle(t *testing.T) {
|
||||
|
||||
func TestFetchDependencyRepos_RKE(t *testing.T) {
|
||||
|
||||
errorPullImageList, errorGzipImageList, realCmiiImageName, allGzipFileNameList := DownloadCompressUploadDependency(true, true, false, true)
|
||||
errorPullImageList, errorGzipImageList, realCmiiImageName, allGzipFileNameList := C_DownloadCompressUploadDependency(true, true, false, true)
|
||||
|
||||
utils.BeautifulPrintListWithTitle(errorPullImageList, "errorPullImageList")
|
||||
utils.BeautifulPrintListWithTitle(errorGzipImageList, "errorGzipImageList")
|
||||
@@ -50,18 +50,15 @@ func TestPullFromEntityAndSyncConditionally(t *testing.T) {
|
||||
sync := ImageSyncEntity{
|
||||
CmiiNameTagList: []string{
|
||||
"cmii-uav-mqtthandler:5.4.0-bjdyt-052102",
|
||||
"cmii-uav-industrial-portfolio:5.4.0-bjdyt-052801",
|
||||
"cmii-uav-platform-armypeople:5.4.0-bjdyt-052802",
|
||||
"cmii-uav-platform:5.4.0-bjdyt-052901",
|
||||
},
|
||||
FullNameImageList: nil,
|
||||
ProjectVersion: "",
|
||||
ProjectName: "bjtg",
|
||||
DirectHarborHost: "10.250.0.110",
|
||||
DownloadImage: true,
|
||||
CompressImageToGzip: false,
|
||||
UploadToDemoMinio: false,
|
||||
ShouldDirectPushToHarbor: true,
|
||||
FullNameImageList: nil,
|
||||
ProjectVersion: "",
|
||||
ProjectName: "cqsh",
|
||||
DirectHarborHost: "chongqingcis-9b4a3da9.ecis.chongqing-1.cmecloud.cn",
|
||||
ShouldDownloadImage: true,
|
||||
ShouldCompressImageToGzip: false,
|
||||
ShouldUploadToDemoMinio: false,
|
||||
ShouldDirectPushToHarbor: true,
|
||||
}
|
||||
|
||||
// 调用函数并获取结果。这里需要根据你的实际需求来验证返回的结果是否符合预期。
|
||||
@@ -87,7 +84,7 @@ func TestDownloadLoadTagUpload(t *testing.T) {
|
||||
for _, s := range localGzipFileList {
|
||||
log.InfoF("start to sync => %s", s)
|
||||
|
||||
targetImageFullNameList := DownloadLoadTagUpload(false, "", "", s, "172.28.0.251:8033")
|
||||
targetImageFullNameList := A_DownloadLoadTagUpload(false, "", "", s, "172.28.0.251:8033")
|
||||
|
||||
utils.BeautifulPrintListWithTitle(targetImageFullNameList, "targetImageFullNameList")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user