Skip to content
This repository was archived by the owner on Jul 27, 2022. It is now read-only.

Problem:(CRO-574) integration test cannot run on linux#579

Merged
bors[bot] merged 1 commit intocrypto-com:masterfrom
leejw51crypto:cro-574
Nov 14, 2019
Merged

Problem:(CRO-574) integration test cannot run on linux#579
bors[bot] merged 1 commit intocrypto-com:masterfrom
leejw51crypto:cro-574

Conversation

@leejw51crypto
Copy link
Copy Markdown
Collaborator

Solution: add fixes for linux
fix env error

add sudo

@leejw51crypto
Copy link
Copy Markdown
Collaborator Author

you can activate integration test on linux , mac
like this

export SGX_MODE=sw
export NETWORK_ID = ab
export USE_DOCKER_COMPOSE= 1


cd integration-tests
./prepare.sh
. ./env.sh
docker-compose up

cd integration-tests
cd client-rpc
yarn
yarn test

@leejw51crypto
Copy link
Copy Markdown
Collaborator Author

thanks @calvinaco @tomtau

@leejw51crypto
Copy link
Copy Markdown
Collaborator Author

getting scripts' absolute path is necessary,
in non interactive shell,
it's -bash <- $0

print_step "Cloning Tendermint config from \"${1}\" to \"${2}\""

rm -rf "${2}"
sudo rm -rf "${2}"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

in travis, it is no problem, because it's root.
so i added sudo for these commands.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

why is sudo required?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

because in running,
./prepare.sh
it makes root owned file inside docker,
so external shell is normal user,
it cannot continue

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

i didn't execute as root and it worked fine

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@calvinaco @calvinlauco is sudo really required?

Copy link
Copy Markdown
Collaborator Author

@leejw51crypto leejw51crypto Nov 13, 2019

Choose a reason for hiding this comment

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

which folder did you run the script?
for me, i ran inside intergration_tests folder.
cd integrations-tests
./prepare.sh

for me, it always fails to compile

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

doing sudo also seems overkill; maybe after each generated docker-data, try to change the ownership to the current user?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

agree, i will try different approach

@codecov
Copy link
Copy Markdown

codecov bot commented Nov 12, 2019

Codecov Report

Merging #579 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #579   +/-   ##
=======================================
  Coverage   67.73%   67.73%           
=======================================
  Files         124      124           
  Lines       14785    14785           
=======================================
  Hits        10015    10015           
  Misses       4770     4770

Copy link
Copy Markdown
Contributor

@tomtau tomtau left a comment

Choose a reason for hiding this comment

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

i don't think sudo should be required for running integration tests -- also, here sudo was inserted in front of rm -rf <some env variable> which looks dangerous, especially as there are no checks on if these environment variables were set properly

@leejw51 leejw51 force-pushed the cro-574 branch 2 times, most recently from cebe902 to d1ebf10 Compare November 13, 2019 03:15
@leejw51crypto
Copy link
Copy Markdown
Collaborator Author

ok, i will find a way to bypass

@leejw51crypto
Copy link
Copy Markdown
Collaborator Author

removed sudo,
chmod ug+s docker-data

@tomtau tomtau changed the title Problem:(CRO-574) integration test not compiled on linux Problem:(CRO-574) integration test cannot run on linux Nov 13, 2019
@tomtau tomtau self-requested a review November 13, 2019 10:40
Copy link
Copy Markdown
Contributor

@tomtau tomtau left a comment

Choose a reason for hiding this comment

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

seems ok -- can you squash the commits?

@leejw51crypto
Copy link
Copy Markdown
Collaborator Author

ok, i will

@leejw51 leejw51 force-pushed the cro-574 branch 4 times, most recently from 4babf8b to 977f5e2 Compare November 13, 2019 11:40
Solution: add fixes for linux
fix env error

add sudo


add -- option

add -- option


remove sudo

restore wallet client


remove hdwallet test

remove hdwallet test


fix copy error
@leejw51crypto
Copy link
Copy Markdown
Collaborator Author

done!
good to go

@tomtau
Copy link
Copy Markdown
Contributor

tomtau commented Nov 14, 2019

bors r+

bors bot added a commit that referenced this pull request Nov 14, 2019
579: Problem:(CRO-574)  integration test cannot run on linux r=tomtau a=leejw51crypto

Solution: add fixes for linux
fix env error

add sudo



580: Bump unicase from 2.5.1 to 2.6.0 r=tomtau a=dependabot-preview[bot]

Bumps [unicase](https://github.com/seanmonstar/unicase) from 2.5.1 to 2.6.0.
<details>
<summary>Release notes</summary>

*Sourced from [unicase's releases](https://github.com/seanmonstar/unicase/releases).*

> ## v2.6.0
> - Fix `UniCase::eq` in Unicode mode so that it doesn't equal a substring of the other.
> - Make crate `no_std`.
</details>
<details>
<summary>Commits</summary>

- [`7b116bc`](seanmonstar/unicase@7b116bc) v2.6.0
- [`c14856b`](seanmonstar/unicase@c14856b) Fix Unicode::eq to not equal when one side is a substring of the other ([#39](https://github-redirect.dependabot.com/seanmonstar/unicase/issues/39))
- [`4788cba`](seanmonstar/unicase@4788cba) update version_check
- [`fbab380`](seanmonstar/unicase@fbab380) Implement no_std support ([#34](https://github-redirect.dependabot.com/seanmonstar/unicase/issues/34))
- See full diff in [compare view](seanmonstar/unicase@v2.5.1...v2.6.0)
</details>
<br />

[![Dependabot compatibility score](https://api.dependabot.com/badges/compatibility_score?dependency-name=unicase&package-manager=cargo&previous-version=2.5.1&new-version=2.6.0)](https://dependabot.com/compatibility-score.html?dependency-name=unicase&package-manager=cargo&previous-version=2.5.1&new-version=2.6.0)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language
- `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language
- `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language
- `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme

Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com):
- Update frequency (including time of day and day of week)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)



</details>

584: Problem: client can't trust validators field in genesis api (CRO-101) r=tomtau a=yihuang

Solution:
Validate validators in ``RequestInitChain``, make sure the consistency.

Co-authored-by: jongwhan lee <leejw51@gmail.com>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: yihuang <huang@crypto.com>
@bors
Copy link
Copy Markdown
Contributor

bors bot commented Nov 14, 2019

Build failed (retrying...)

bors bot added a commit that referenced this pull request Nov 14, 2019
579: Problem:(CRO-574)  integration test cannot run on linux r=tomtau a=leejw51crypto

Solution: add fixes for linux
fix env error

add sudo



Co-authored-by: jongwhan lee <leejw51@gmail.com>
@bors
Copy link
Copy Markdown
Contributor

bors bot commented Nov 14, 2019

Build failed

@tomtau
Copy link
Copy Markdown
Contributor

tomtau commented Nov 14, 2019

bors r+

bors bot added a commit that referenced this pull request Nov 14, 2019
579: Problem:(CRO-574)  integration test cannot run on linux r=tomtau a=leejw51crypto

Solution: add fixes for linux
fix env error

add sudo



Co-authored-by: jongwhan lee <leejw51@gmail.com>
@bors
Copy link
Copy Markdown
Contributor

bors bot commented Nov 14, 2019

@bors bors bot merged commit 4971789 into crypto-com:master Nov 14, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants