omni / bridge-ui

UI for TokenBridge, an interoperability solution between Ethereum networks for native and ERC tokens
https://bridge.poa.net/
41 stars 51 forks source link

End-to-End tests not working #216

Closed rzadp closed 5 years ago

rzadp commented 5 years ago

The e2e script is not working for me.

Steps to reproduce

git clone https://github.com/poanetwork/bridge-ui.git
cd bridge-ui
git checkout --track origin/develop
git submodule update --init
npm install
cd e2e-script
./run-tests.sh

Result

The tests hang forever on "Connecting"

Screenshot 2019-05-15 at 12 01 45

No errors up to this point. After a while the console starts erroring:

Screenshot 2019-05-15 at 12 02 50

My setup

rzadp commented 5 years ago

@patitonar

patitonar commented 5 years ago

I followed the steps to reproduce the issue and it worked OK for me. From the error it seems that the parity node is not responding. Can you provide the full logs? Also, the only external dependencies are Docker and docker-compose. Which versions are you using?

My setup: Node v10.15.1 npm 6.4.1 Docker version 18.09.5 docker-compose version 1.21.2

rzadp commented 5 years ago

My setup:

Docker Community version 18.09.2 docker-compose version 1.23.2

Here is the output when running run-tests.sh. https://gist.github.com/rzadp/54b3327c5e47dd57e1f41964e5bf1f6b Not sure if there are some log files beside this.

patitonar commented 5 years ago

From the logs everything looks OK.

The issue seems to be at trying to reach the parity node (and probably the ui page too) from the browser on the test that is running outside docker. For that it is using the container IPs, but It seems that you cannot access container IPs directly on mac. This works OK on linux, that's why I'm not able to reproduce the issue.

Here is more information: https://docs.docker.com/docker-for-mac/networking/#known-limitations-use-cases-and-workarounds

I will update the code to use the exposed ports on localhost instead of container IPs and open a PR for that.

akolotov commented 5 years ago

@rzadp @patitonar consider to create a PR for this issue in the monorepo directly.

rzadp commented 5 years ago

@rzadp @patitonar consider to create a PR for this issue in the monorepo directly.

I'll create the PR with these changes in the monorepo

akolotov commented 5 years ago

So, I will close this issue.