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

tests: Preserve data dir from failed linearizability tests #14714

Merged
merged 1 commit into from
Nov 10, 2022

Conversation

serathius
Copy link
Member

cc @ahrtr

@codecov-commenter
Copy link

Codecov Report

Merging #14714 (c81849c) into main (f482f7b) will decrease coverage by 0.11%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main   #14714      +/-   ##
==========================================
- Coverage   75.56%   75.44%   -0.12%     
==========================================
  Files         457      457              
  Lines       37308    37308              
==========================================
- Hits        28191    28148      -43     
- Misses       7351     7381      +30     
- Partials     1766     1779      +13     
Flag Coverage Δ
all 75.44% <ø> (-0.12%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
client/pkg/v3/tlsutil/tlsutil.go 83.33% <0.00%> (-8.34%) ⬇️
client/v3/leasing/util.go 91.66% <0.00%> (-6.67%) ⬇️
server/lease/lease.go 94.87% <0.00%> (-5.13%) ⬇️
server/etcdserver/txn/util.go 75.47% <0.00%> (-3.78%) ⬇️
server/etcdserver/api/v3rpc/util.go 70.96% <0.00%> (-3.23%) ⬇️
client/v3/leasing/txn.go 88.09% <0.00%> (-3.18%) ⬇️
server/etcdserver/api/v3rpc/interceptor.go 73.43% <0.00%> (-3.13%) ⬇️
client/v3/concurrency/election.go 79.68% <0.00%> (-2.35%) ⬇️
server/etcdserver/api/v3rpc/auth.go 79.34% <0.00%> (-2.18%) ⬇️
api/etcdserverpb/raft_internal_stringer.go 81.72% <0.00%> (-2.16%) ⬇️
... and 14 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

tests/linearizability/linearizability_test.go Outdated Show resolved Hide resolved
tests/linearizability/linearizability_test.go Outdated Show resolved Hide resolved
tests/linearizability/linearizability_test.go Outdated Show resolved Hide resolved
}
err = os.MkdirAll(path, 0700)
if err != nil {
t.Error(err)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

t.Error(err) means that the test will continue to execute .

Suggested change
t.Error(err)
t.Fatal(err)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will still want to report model not linearizable even if writing report will not work.

tests/linearizability/linearizability_test.go Outdated Show resolved Hide resolved
tests/linearizability/linearizability_test.go Outdated Show resolved Hide resolved
@ahrtr
Copy link
Member

ahrtr commented Nov 10, 2022

Please consider to use github.com/stretchr/testify to simplify the checking on test results.

Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
@serathius
Copy link
Member Author

Please consider to use github.com/stretchr/testify to simplify the checking on test results.

Sure, maybe as a followup PR. I would want to first understand how looks testify addoption throughout other tests.

Copy link
Member

@ahrtr ahrtr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@serathius serathius merged commit 2f558ca into etcd-io:main Nov 10, 2022
@serathius serathius deleted the linearizability-data-dir branch June 15, 2023 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

3 participants