Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix failing testcases for PR #1043 #1077

Merged
merged 110 commits into from
Jul 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
110 commits
Select commit Hold shift + click to select a range
ea645f1
Initial TC suite #987
CristalWilsonLobo Feb 14, 2024
f2060d9
go mod tidy
Jayashsatolia403 Mar 10, 2024
da47b3c
Restricted blobber tests
Jayashsatolia403 Mar 20, 2024
a9422df
Changed repo snapshots
Jayashsatolia403 Mar 20, 2024
27ac46f
Merge branch 'master' into sprint-1.14
Jayashsatolia403 Mar 26, 2024
8c57f3b
duplicate file name tc rollback allocation
CristalWilsonLobo Apr 2, 2024
e0994b0
Merge branch 'refs/heads/master' into sprint-1.14
Jayashsatolia403 Apr 2, 2024
d21f717
Merge branch 'refs/heads/master' into sprint-1.14
Jayashsatolia403 Apr 2, 2024
803ba50
Skipped authorizer tests
Jayashsatolia403 Apr 2, 2024
49f095b
Merge branch 'refs/heads/master' into sprint-1.14
Jayashsatolia403 Apr 2, 2024
3defc77
Merge branch 'master' into rollback_allocation_tc
CristalWilsonLobo Apr 2, 2024
74f5ae2
Multiple update and delete
CristalWilsonLobo Apr 2, 2024
a8a171e
updated multi-file upload tests
CristalWilsonLobo Apr 3, 2024
6b4fcb1
Interruped file upload
CristalWilsonLobo Apr 3, 2024
f1cbede
add owner api calls (#1047)
Sanchit011 Apr 7, 2024
444f542
Added feature blobber auth tests
Jayashsatolia403 Apr 8, 2024
6a6e660
Fix API tests create allocation
Jayashsatolia403 Apr 8, 2024
4a99711
Updated gosdk
Jayashsatolia403 Apr 8, 2024
37d9664
Merge branch 'refs/heads/sprint-1.14' into feature/blobber-auth
Jayashsatolia403 Apr 8, 2024
90f92ec
Updated gosdk
Jayashsatolia403 Apr 8, 2024
3990f94
Fix
Jayashsatolia403 Apr 8, 2024
32f1bc1
Fix
Jayashsatolia403 Apr 8, 2024
eff1e13
Fix blobber config update test =
Jayashsatolia403 Apr 8, 2024
48f7f65
Fix blobber config update cleanup
Jayashsatolia403 Apr 8, 2024
ff1b743
Fix
Jayashsatolia403 Apr 8, 2024
d5cb623
Hotfix/0box (#1049)
Sanchit011 Apr 9, 2024
b114d8e
Updated gosdk
Jayashsatolia403 Apr 11, 2024
c0218cd
fix commit err message (#1052)
Hitenjain14 Apr 11, 2024
274393e
Fix
Jayashsatolia403 Apr 14, 2024
5d494ef
Fix
Jayashsatolia403 Apr 14, 2024
f7d76d8
Fix
Jayashsatolia403 Apr 14, 2024
03b3e24
Fix
Jayashsatolia403 Apr 14, 2024
f557e07
Fix
Jayashsatolia403 Apr 14, 2024
5906a73
Fix
Jayashsatolia403 Apr 14, 2024
c4b29b2
Fix lint
Jayashsatolia403 Apr 14, 2024
67ae7ee
Fix
Jayashsatolia403 Apr 14, 2024
cd10097
Merge pull request #1031 from 0chain/feature/blobber-auth
dabasov Apr 14, 2024
619a423
tests to list stakable providers (#1036)
storybehind Apr 15, 2024
43f0884
Fix 0box tests with create allocation
Jayashsatolia403 Apr 15, 2024
069c96a
fix 0box tests
Sanchit011 Apr 15, 2024
9ba204a
Empty commit
Jayashsatolia403 Apr 16, 2024
1e20724
Fix restricted blobber tests
Jayashsatolia403 Apr 16, 2024
be7287d
Merge pull request #1054 from 0chain/fix/0box-tests
dabasov Apr 16, 2024
6a49c1d
Merge branch 'refs/heads/master' into sprint-1.14
Jayashsatolia403 Apr 22, 2024
11a6f88
Merge branch 'master' into sprint-1.14
Jayashsatolia403 Apr 22, 2024
a455567
Merge branch 'refs/heads/master' into sprint-1.14
Jayashsatolia403 Apr 22, 2024
ca51ad2
Update gosdk
Jayashsatolia403 Apr 23, 2024
b57c34f
Fix sharder config update
Jayashsatolia403 Apr 24, 2024
c826906
fix delete wallet (#1057)
Sanchit011 Apr 27, 2024
a64f648
Fixed file format and restricted blobbers test
Jayashsatolia403 Apr 28, 2024
055f288
Fix resume upload
Jayashsatolia403 Apr 28, 2024
6f8e983
Fix restricted blobbers
Jayashsatolia403 Apr 28, 2024
763c02c
fix resume download test (#1058)
Hitenjain14 Apr 28, 2024
22c07a9
Fix restricted blobbers
Jayashsatolia403 Apr 29, 2024
6581305
Fix restricted blobbers
Jayashsatolia403 Apr 29, 2024
df4597d
Fix restricted blobbers
Jayashsatolia403 Apr 29, 2024
15d8c16
added repair allocation with diff file size (#1034)
Zorro30 Apr 30, 2024
fd78ea0
Merge branch 'refs/heads/sprint-1.14' into rollback_allocation_tc
Jayashsatolia403 Apr 30, 2024
2772ccc
added test suite for dropbox
pewssh May 1, 2024
967e5cf
test suite for gdrive
pewssh May 1, 2024
3dba307
updated for workflow
pewssh May 2, 2024
a17b590
lint fix
pewssh May 2, 2024
acc5176
changes for dropbox tests
pewssh May 5, 2024
66cdcd6
Fix: Issue previous test cases
pewssh May 5, 2024
fe1aeb9
Added lib
pewssh Jun 13, 2024
3a32014
Resolve conflicts
pewssh Jun 13, 2024
4a7553e
disable lint
pewssh Jun 13, 2024
8eb4645
add TestRepairSize
storybehind Jun 14, 2024
cf72129
add cli tests
storybehind Jun 14, 2024
8e451f9
update gosdk version
storybehind Jun 14, 2024
5a98103
apply gofmt
storybehind Jun 14, 2024
06eee02
Merge pull request #1071
Jayashsatolia403 Jun 16, 2024
ce23fa8
Merge branch 'master' into sprint-1.16
Jayashsatolia403 Jun 18, 2024
8ef432a
Merge pull request #1072 from 0chain/repair-size
dabasov Jun 21, 2024
be7e288
Merge branch 'sprint-1.16' into rollback_allocation_tc
Jayashsatolia403 Jun 25, 2024
cf0c3e8
add remotepath in the file upload for rollback_allocation_after_multi…
yash10019coder Jun 26, 2024
7fc0d9c
nit fix for remotepath in the prev test case fix.
yash10019coder Jun 28, 2024
10c6f13
fix remotepath for rollback allocation after multiple files upload an…
yash10019coder Jun 28, 2024
39e1a8f
refactor: assertion in rollback allocation test case.
yash10019coder Jun 30, 2024
039249c
nit fixes.
yash10019coder Jun 30, 2024
b58df88
nit fixes.
yash10019coder Jun 30, 2024
c015af7
saving file names as they are generated at random from generateFileAn…
yash10019coder Jun 30, 2024
1b1ffdf
added wait groups for file uploads.
yash10019coder Jul 1, 2024
7a48a6c
downloading the file after uploading and then getting the checksum.
yash10019coder Jul 2, 2024
93a1ef1
fix waitgroup for uploading multiple files and delete single file tes…
yash10019coder Jul 2, 2024
13fa12f
fix nil map error.
yash10019coder Jul 2, 2024
f4b05ce
fix test for multiple files upload and single file delete in rollback…
yash10019coder Jul 2, 2024
5fcf9b5
fix test multiple files upload and single file update (updating a fil…
yash10019coder Jul 3, 2024
6a1745a
remove wait group for updating a large file test.
yash10019coder Jul 3, 2024
81181fd
add test for updating file multiple times and then rolling back.
yash10019coder Jul 7, 2024
ed5dc6d
refactor: updating single files multiple times test case.
yash10019coder Jul 7, 2024
73003f7
refactor: rollback while updating a large file should work.
yash10019coder Jul 7, 2024
ddd1f92
Merge branch 'master' into fix-rollback-allocation-unit-tests
yash10019coder Jul 7, 2024
6413133
refactor: rollback while updating a large file should work.
yash10019coder Jul 8, 2024
4d0eb29
nit fixes.
yash10019coder Jul 8, 2024
65ee970
add some logs
yash10019coder Jul 9, 2024
e04caf6
add new testcase involving large file rollback with a small file upload.
yash10019coder Jul 9, 2024
ca3d74b
removed file removal as this is created on the /tmp dir.
yash10019coder Jul 10, 2024
01a2c8e
removed file removal as this is created on the /tmp dir.
yash10019coder Jul 10, 2024
ce9b6f0
refactor: assertion for large file test case.
yash10019coder Jul 10, 2024
1df5311
removed unnecessary delay for large files.
yash10019coder Jul 10, 2024
505b62b
refactor: add update small file for large files rollback test.
yash10019coder Jul 10, 2024
6fe439f
update gosdk to latest staging.
yash10019coder Jul 11, 2024
8bc3745
file uploads are very fast on ci so increased the filesize and decrea…
yash10019coder Jul 12, 2024
dfbbd93
fix lint errors.
yash10019coder Jul 13, 2024
4710c69
fix lint errors.
yash10019coder Jul 13, 2024
a5cbd44
Merge branch 'sprint-1.17' of github.com:0chain/system_test into fix-…
yash10019coder Jul 15, 2024
c73c120
nit fixes.
yash10019coder Jul 15, 2024
a228599
test run
yash10019coder Jul 15, 2024
c4f9026
Merge branch 'sprint-1.17' of github.com:0chain/system_test into fix-…
yash10019coder Jul 15, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tests/cli_tests/0_challenge_protocol_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -275,8 +275,8 @@ func TestProtocolChallenge(testSetup *testing.T) {
}

// Generate a random number in the range [0, max)
func secureRandomInt(max int) (int64, error) {
n, err := rand.Int(rand.Reader, big.NewInt(int64(max)))
func secureRandomInt(maxValue int) (int64, error) {
n, err := rand.Int(rand.Reader, big.NewInt(int64(maxValue)))
if err != nil {
return 0, err
}
Expand Down
17 changes: 17 additions & 0 deletions tests/cli_tests/zboxcli_common_user_functions_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,23 @@ func updateFileWithRandomlyGeneratedDataWithWallet(t *test.SystemTest, walletNam
return localfile
}

func updateFileContentWithRandomlyGeneratedData(t *test.SystemTest, allocationID, remotepath, filename string, size int64) string {
return updateFileContentWithRandomlyGeneratedDataWithWallet(t, escapedTestName(t), allocationID, remotepath, filename, size)
}

func updateFileContentWithRandomlyGeneratedDataWithWallet(t *test.SystemTest, walletName, allocationID, remotepath, filename string, size int64) string {
err := createFileWithSize(filename, size)
require.Nil(t, err)

output, err := updateFileWithWallet(t, walletName, configPath, map[string]interface{}{
"allocation": allocationID,
"remotepath": remotepath,
"localpath": filename,
}, true)
require.Nil(t, err, strings.Join(output, "\n"))
return filename
}

func renameFile(t *test.SystemTest, cliConfigFilename string, param map[string]interface{}, retry bool) ([]string, error) {
t.Logf("Renaming file...")
p := createParams(param)
Expand Down
20 changes: 20 additions & 0 deletions tests/cli_tests/zboxcli_file_upload_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1034,6 +1034,26 @@ func generateFileAndUploadForWallet(t *test.SystemTest, wallet, allocationID, re
return filename
}

func generateFileContentAndUpload(t *test.SystemTest, allocationID, remotepath, filename string, size int64) string {
return generateFileContentAndUploadForWallet(t, escapedTestName(t), allocationID, remotepath, filename, size)
}

func generateFileContentAndUploadForWallet(t *test.SystemTest, wallet, allocationID, remotepath, filename string, size int64) string {
err := createFileWithSize(filename, size)
require.Nil(t, err)

// Upload parameters
// log command with allocation id, filename and remotepath
t.Logf("Uploading file %s to allocation %s with remotepath %s", filename, allocationID, remotepath+filepath.Base(filename))
uploadWithParamForWallet(t, wallet, configPath, map[string]interface{}{
"allocation": allocationID,
"localpath": filename,
"remotepath": remotepath + filepath.Base(filename),
})

return filename
}

func generateFileAndUploadWithParam(t *test.SystemTest, allocationID, remotepath string, size int64, params map[string]interface{}) string {
filename := generateRandomTestFileName(t)

Expand Down
Loading
Loading