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

Use LineBuffering in unit tests #2723

Merged
merged 3 commits into from
Jun 18, 2021
Merged

Conversation

Anviking
Copy link
Member

@Anviking Anviking commented Jun 17, 2021

Issue Number

ADP-970 / #2472

Overview

  • Try using line buffering in unit tests, like we do for integration tests

Comments

We use it in the integration tests. Maybe it will improve the unit
timeouts or our understanding of it - could be worth a shot.
Copy link
Contributor

@rvl rvl left a comment

Choose a reason for hiding this comment

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

Oh yes, I was going to mention this but forgot... With this change we will see exactly where it gets stuck.

Copy link
Contributor

@rvl rvl left a comment

Choose a reason for hiding this comment

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

Good thanks - I added a Test.Utils.Startup.withLineBuffering function for this, and slightly reorganised the Test.Utils. modules.

@rvl
Copy link
Contributor

rvl commented Jun 18, 2021

bors r+

iohk-bors bot added a commit that referenced this pull request Jun 18, 2021
2721: Ensure faucet setup runs on BFT node without rollbacks r=rvl a=Anviking

# Issue Number

ADP-970, #2720, #2428


# Overview

<!-- Detail in a few bullet points the work accomplished in this PR -->

- [x] Ensure faucet setup runs on BFT node, such that rollbacks can't mess it up


# Comments

<!-- Additional comments or screenshots to attach if any -->

<!--
Don't forget to:

 ✓ Self-review your changes to make sure nothing unexpected slipped through
 ✓ Assign yourself to the PR
 ✓ Assign one or several reviewer(s)
 ✓ Jira will detect and link to this PR once created, but you can also link this PR in the description of the corresponding ticket
 ✓ Acknowledge any changes required to the Wiki
 ✓ Finally, in the PR description delete any empty sections and all text commented in <!--, so that this text does not appear in merge commit messages.
-->


2723: Use LineBuffering in unit tests r=rvl a=Anviking

# Issue Number

ADP-970 / #2472 


# Overview

<!-- Detail in a few bullet points the work accomplished in this PR -->

- [x] Try using line buffering in unit tests, like we do for integration tests


# Comments

<!-- Additional comments or screenshots to attach if any -->

<!--
Don't forget to:

 ✓ Self-review your changes to make sure nothing unexpected slipped through
 ✓ Assign yourself to the PR
 ✓ Assign one or several reviewer(s)
 ✓ Jira will detect and link to this PR once created, but you can also link this PR in the description of the corresponding ticket
 ✓ Acknowledge any changes required to the Wiki
 ✓ Finally, in the PR description delete any empty sections and all text commented in <!--, so that this text does not appear in merge commit messages.
-->


Co-authored-by: Johannes Lund <[email protected]>
Co-authored-by: Rodney Lorrimar <[email protected]>
@iohk-bors
Copy link
Contributor

iohk-bors bot commented Jun 18, 2021

Build failed (retrying...):

#duplicate

iohk-bors bot added a commit that referenced this pull request Jun 18, 2021
2723: Use LineBuffering in unit tests r=rvl a=Anviking

# Issue Number

ADP-970 / #2472 


# Overview

<!-- Detail in a few bullet points the work accomplished in this PR -->

- [x] Try using line buffering in unit tests, like we do for integration tests


# Comments

<!-- Additional comments or screenshots to attach if any -->

<!--
Don't forget to:

 ✓ Self-review your changes to make sure nothing unexpected slipped through
 ✓ Assign yourself to the PR
 ✓ Assign one or several reviewer(s)
 ✓ Jira will detect and link to this PR once created, but you can also link this PR in the description of the corresponding ticket
 ✓ Acknowledge any changes required to the Wiki
 ✓ Finally, in the PR description delete any empty sections and all text commented in <!--, so that this text does not appear in merge commit messages.
-->


Co-authored-by: Johannes Lund <[email protected]>
Co-authored-by: Rodney Lorrimar <[email protected]>
@iohk-bors
Copy link
Contributor

iohk-bors bot commented Jun 18, 2021

Build failed:

cardano-wallet             &gt;   src/Test/Integration/Scenario/CLI/Shelley/Wallets.hs:754:18:
--
&nbsp; | cardano-wallet             &gt;   1) CLI Specifications, SHELLEY_CLI_WALLETS, WALLETS_UTXO_02 - Utxo statistics works properly
&nbsp; | cardano-wallet             &gt;        Waited longer than 90s to resolve action: "Wallet balance is as expected".
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:2322] [2021-06-18 03:25:12.91 UTC] Connection lost with the node. Network.Socket.recvBuf: resource vanished (Connection reset by peer)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51902] [2021-06-18 03:25:12.91 UTC] Connection lost with the node. Network.Socket.recvBuf: resource vanished (Connection reset by peer)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51833] [2021-06-18 03:25:12.91 UTC] Connection lost with the node. Network.Socket.recvBuf: resource vanished (Connection reset by peer)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:2320] [2021-06-18 03:25:12.93 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt;        expected: Quantity {getQuantity = 1562000000}
&nbsp; | cardano-wallet             &gt;         but got: Quantity {getQuantity = 0}
&nbsp; | cardano-wallet             &gt;
&nbsp; | cardano-wallet             &gt;   To rerun use: --match "/CLI Specifications/SHELLEY_CLI_WALLETS/WALLETS_UTXO_02 - Utxo statistics works properly/"
&nbsp; | cardano-wallet             &gt;
&nbsp; | cardano-wallet             &gt;   src/Test/Integration/Scenario/CLI/Shelley/HWWallets.hs:129:18:
&nbsp; | cardano-wallet             &gt;   2) CLI Specifications, SHELLEY_CLI_HW_WALLETS, HW_WALLETS_01x - Restoration from account public key preserves funds
&nbsp; | cardano-wallet             &gt;        Waited longer than 90s to resolve action: "Wallet balance is as expected".
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51843] [2021-06-18 03:25:13.05 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51855] [2021-06-18 03:25:13.06 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51769] [2021-06-18 03:25:13.07 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51900] [2021-06-18 03:25:13.07 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:53458] [2021-06-18 03:25:13.07 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51665] [2021-06-18 03:25:13.08 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51793] [2021-06-18 03:25:13.08 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:53420] [2021-06-18 03:25:13.08 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51898] [2021-06-18 03:25:13.08 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:52011] [2021-06-18 03:25:13.08 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt; [cardano-wallet.network:Warning:51992] [2021-06-18 03:25:13.09 UTC] Connection lost with the node. writev: resource vanished (Broken pipe)
&nbsp; | cardano-wallet             &gt;        expected: Quantity {getQuantity = 1000000}
&nbsp; | cardano-wallet             &gt;         but got: Quantity {getQuantity = 0}
&nbsp; | cardano-wallet             &gt;
&nbsp; | cardano-wallet             &gt;   To rerun use: --match "/CLI Specifications/SHELLEY_CLI_HW_WALLETS/HW_WALLETS_01x - Restoration from account public key preserves funds/"

#2428

@Anviking
Copy link
Member Author

bors r+

@iohk-bors
Copy link
Contributor

iohk-bors bot commented Jun 18, 2021

Build succeeded:

@iohk-bors iohk-bors bot merged commit b087c03 into master Jun 18, 2021
@iohk-bors iohk-bors bot deleted the anviking/ADP-970/lineBuffering branch June 18, 2021 08:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants