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

lease: test minLeaseTTL limit #8537

Merged
merged 1 commit into from
Sep 12, 2017
Merged

lease: test minLeaseTTL limit #8537

merged 1 commit into from
Sep 12, 2017

Conversation

lorneli
Copy link
Contributor

@lorneli lorneli commented Sep 9, 2017

Test whether lease's ttl is set to minLeaseTTL when passing a ttl smaller than minLeaseTTL to Grant function.

@@ -45,10 +45,16 @@ func TestLessorGrant(t *testing.T) {
defer le.Stop()
le.Promote(0)

l, err := le.Grant(1, 1)
ttl := int64(1) // ttl <= minLeaseTTL in this test case
Copy link
Contributor

Choose a reason for hiding this comment

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

please don't introduce this new variable, there's more changes from adding ttl than code for what this patch is testing

Test whether lease's ttl is set to minLeaseTTL when passing a ttl
smaller than minLeaseTTL to Grant function.
@lorneli
Copy link
Contributor Author

lorneli commented Sep 12, 2017

I have removed ttl variable.

@codecov-io
Copy link

Codecov Report

❗ No coverage uploaded for pull request base (master@9553afb). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #8537   +/-   ##
=========================================
  Coverage          ?   66.02%           
=========================================
  Files             ?      360           
  Lines             ?    29551           
  Branches          ?        0           
=========================================
  Hits              ?    19511           
  Misses            ?     8373           
  Partials          ?     1667

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9553afb...28a2207. Read the comment docs.

Copy link
Contributor

@heyitsanthony heyitsanthony left a comment

Choose a reason for hiding this comment

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

lgtm thanks

@xiang90
Copy link
Contributor

xiang90 commented Sep 12, 2017

lgtm

@xiang90 xiang90 merged commit 510d884 into etcd-io:master Sep 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants