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

beefed up test #16

Closed
wants to merge 3 commits into from
Closed

Conversation

DougAnderson444
Copy link

Hi Mauve,

I had some trouble getting Hyperswarm-web client working locally with a local server, the result of that trouble is this verbose test.

Thought I'd toss this up into a PR since there may be someone else struggling to make it work, the code example in the test might help them too?

Backstory: Turns out { announceLocalAddress: true } seems to be critical for a local client to connect to a local hyperswarm-web server? As soon as that was added, all my troubles seemed to melt away. Only saw it deep in the hyperswarm example code, wasn't really documented anywhere.

    const hostname = `ws://localhost:${port}`

    const client = hyperswarmweb({
      announceLocalAddress: true,
      wsProxy: [hostname]
    })

@DougAnderson444
Copy link
Author

Hmm, maybe I spoke too soon about the announceLocalAddress, but the test is still valid 🤔

@RangerMauve
Copy link
Owner

Interesting, what does this test cover that wasn't before?

I'd be down to merge if you could remove the commented out code and added t.pass or t.fail assertions instead of console logs. 😁

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.

None yet

2 participants