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 should not create a NetworkController instance where possible #1051

Closed
5 tasks done
BelfordZ opened this issue Jan 10, 2023 · 2 comments · Fixed by #1053 or #1062
Closed
5 tasks done

Tests should not create a NetworkController instance where possible #1051

BelfordZ opened this issue Jan 10, 2023 · 2 comments · Fixed by #1053 or #1062

Comments

@BelfordZ
Copy link
Contributor

BelfordZ commented Jan 10, 2023

Many unit tests create an instance of the network controller when they could easily be mocking out functionality of it. The tests would benefit most from this change:

BelfordZ added a commit that referenced this issue Jan 17, 2023
#1053)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`NftDetectionController` tests.

partially fixes #1051

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
BelfordZ added a commit that referenced this issue Jan 17, 2023
…#1062)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenDetectionController` tests.

partially fixes #1051

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
@BelfordZ BelfordZ reopened this Jan 17, 2023
@BelfordZ
Copy link
Contributor Author

BelfordZ commented Jan 17, 2023

it appears gh doesnt like my use of partially fixes #ISSUE NUMBER

what would be the appropriate keyword to use so that gh doesnt auto close this issue every time a PR is merged from the list?

@Gudahtt
Copy link
Member

Gudahtt commented Jan 24, 2023

I think it sees the "Closes #___" part, and doesn't pay attention to what comes before that.

I've used "Relates to #___" in past. It doesn't result in any linking.

BelfordZ added a commit that referenced this issue Jan 26, 2023
…1052)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the `NftController`
tests.

Relates to #1051
BelfordZ added a commit that referenced this issue Jan 27, 2023
#1061)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenListController` tests.

Relates to #1051

---------

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
BelfordZ added a commit that referenced this issue Jan 27, 2023
#1050)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenController` tests.

Relates to #1051

---------

Co-authored-by: Elliot Winkler <elliot.winkler@gmail.com>
MajorLift pushed a commit that referenced this issue Oct 11, 2023
#1053)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`NftDetectionController` tests.

partially fixes #1051

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
MajorLift pushed a commit that referenced this issue Oct 11, 2023
…#1062)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenDetectionController` tests.

partially fixes #1051

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
MajorLift pushed a commit that referenced this issue Oct 11, 2023
…1052)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the `NftController`
tests.

Relates to #1051
MajorLift pushed a commit that referenced this issue Oct 11, 2023
#1061)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenListController` tests.

Relates to #1051

---------

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
MajorLift pushed a commit that referenced this issue Oct 11, 2023
#1050)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenController` tests.

Relates to #1051

---------

Co-authored-by: Elliot Winkler <elliot.winkler@gmail.com>
MajorLift pushed a commit that referenced this issue Oct 11, 2023
#1053)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`NftDetectionController` tests.

partially fixes #1051

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
MajorLift pushed a commit that referenced this issue Oct 11, 2023
…#1062)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenDetectionController` tests.

partially fixes #1051

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
MajorLift pushed a commit that referenced this issue Oct 11, 2023
…1052)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the `NftController`
tests.

Relates to #1051
MajorLift pushed a commit that referenced this issue Oct 11, 2023
#1061)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenListController` tests.

Relates to #1051

---------

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
MajorLift pushed a commit that referenced this issue Oct 11, 2023
#1050)

**No NetworkController in tests**

**Description**:
Mocking the behaviour of the network controller makes the tests more
flexible, and lessens the burden of cleanup / maintainability of the
tests. This PR removes the `NetworkController` from the
`TokenController` tests.

Relates to #1051

---------

Co-authored-by: Elliot Winkler <elliot.winkler@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment