pingcap / failpoint

An implementation of failpoints for Golang.
Apache License 2.0
817 stars 63 forks source link

failpoint: change the semantics of 'EvalContext' #28

Closed lonng closed 5 years ago

lonng commented 5 years ago

Signed-off-by: Lonng chris@lonng.org

What problem does this PR solve?

Change the semantics of EvalContext

What is changed and how it works?

EvalContext will always return false if context is nil or context does not contain hook function.

Check List

Tests

Side effects

Related changes

codecov[bot] commented 5 years ago

Codecov Report

Merging #28 into master will increase coverage by 0.0148%. The diff coverage is 100%.

@@               Coverage Diff                @@
##             master        #28        +/-   ##
================================================
+ Coverage   86.9169%   86.9318%   +0.0148%     
================================================
  Files             7          7                
  Lines           879        880         +1     
================================================
+ Hits            764        765         +1     
  Misses           73         73                
  Partials         42         42
tiancaiamao commented 5 years ago

LGTM