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

testify: migrate test-infra to testify for distsql_test.go #28574 #30654

Closed
wants to merge 132 commits into from

Conversation

znhh6018
Copy link
Contributor

What problem does this PR solve?

Issue Number: close #28574

Problem Summary:

What is changed and how it works?

Check List

Release note

None

@ti-chi-bot
Copy link
Member

[REVIEW NOTIFICATION]

This pull request has not been approved.

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Dec 12, 2021
@znhh6018
Copy link
Contributor Author

/cc @hawkingrei @tisonkun

@znhh6018
Copy link
Contributor Author

image
if I don't remove "unlint:unsed" on checkGoroutineExists, goword fail.
After I removed "unlint:unsed" and commit , the check_dev fail....

)

// nolint:unused
func checkGoroutineExists(keyword string) bool {
Copy link
Member

Choose a reason for hiding this comment

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

it can remove because no one uses it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

you mean removing the checkGoroutineExists function ?

Copy link
Member

Choose a reason for hiding this comment

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

Yes.

[2021-12-12T12:11:56.974Z] executor/distsql_test.go:43:6: func `checkGoroutineExists` is unused (unused)

[2021-12-12T12:11:56.974Z] func checkGoroutineExists(keyword string) bool {

[2021-12-12T12:11:56.974Z]      ^

Copy link
Contributor Author

Choose a reason for hiding this comment

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

image
I found checkGoroutineExists is called in line 123...

Copy link
Member

Choose a reason for hiding this comment

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

I know.

func checkGoroutineExists(keyword string) bool {

there is the same function.

Copy link
Member

@hawkingrei hawkingrei Dec 13, 2021

Choose a reason for hiding this comment

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

Try to delete executor/distsql_test.go:43:6 checkGoroutineExists or checkGoroutineExists in tidb/executor/seqtest/seq_executor_serial_test.go?

Copy link
Member

Choose a reason for hiding this comment

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

make checkGoroutineExists public and delete the redundant.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

okay , let me try

Copy link
Member

Choose a reason for hiding this comment

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

package name executor_test can be replaced by executor.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I did as follows,
1.make checkGoroutineExists public in tidb/executor/seqtest/seq_executor_serial_test.go
2.package name executor_test replaced by executor in tidb/executor/seqtest/seq_executor_serial_test.go
3.remove checkGoroutineExists in executor/distsql_test.go , use executor.CheckGoroutineExists instead, it prompted CheckGoroutineExists not declared by executor
how could I solve this...

@hawkingrei
Copy link
Member

/run-check_dev

@hawkingrei
Copy link
Member

/run-all-tests

tiancaiamao and others added 16 commits December 23, 2021 14:45
Signed-off-by: yisaer <disxiaofei@163.com>

Co-authored-by: Ti Chi Robot <ti-community-prow-bot@tidb.io>
func (s *testSuite3) TestIndexLookUpGetResultChunk(c *C) {
tk := testkit.NewTestKit(c, s.store)
func TestIndexLookUpGetResultChunk(t *testing.T) {
t.Parallel()
Copy link
Member

Choose a reason for hiding this comment

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

t.Parallel() need to be removed. it is a decision that we have made recently.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

sorry , not familiar with some git operations , things seemed went bad , just close and create a new PR............

@znhh6018 znhh6018 requested a review from a team as a code owner December 25, 2021 14:37
@ti-chi-bot ti-chi-bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Dec 25, 2021
@znhh6018 znhh6018 closed this Dec 25, 2021
@znhh6018 znhh6018 deleted the fix_distsql_test branch December 25, 2021 14:38
@sre-bot
Copy link
Contributor

sre-bot commented Dec 25, 2021

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note-none Denotes a PR that doesn't merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

migrate test-infra to testify for distsql_test.go