question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

const Browser = require('zombie');
const browser = new Browser();
Browser.localhost('http:/www.google.com',3000);
browser.debug();
browser.visit('/');
Sat, 09 Apr 2016 15:11:51 GMT zombie Opened window http://localhost/ 
Sat, 09 Apr 2016 15:11:51 GMT zombie Resource error Error: connect ECONNREFUSED 127.0.0.1:80
    at Object.exports._errnoException (util.js:870:11)
    at exports._exceptionWithHostPort (util.js:893:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1057:14)
Sat, 09 Apr 2016 15:11:51 GMT zombie TypeError: connect ECONNREFUSED 127.0.0.1:80
$ node --version
v4.4.0

What am i doing wrong here? Its also ignoring the port 3000;

Issue Analytics

  • State:open
  • Created 7 years ago
  • Reactions:1
  • Comments:6

github_iconTop GitHub Comments

4reactions
benjickcommented, Aug 31, 2016

Seeing almost the same error

const Browser = require('zombie');
Browser.localhost('example.com', 3000);
const browser = new Browser();
browser.visit('/').then(res => console.log(res));

Gives me TypeError: connect ECONNREFUSED 127.0.0.1:3000

0reactions
giltroymerencommented, Apr 23, 2017

Replicated as well:

  • application running:

    $ npm start
    > app-name@0.0.0 start /path/to/app-name
    node ./bin/www
    
    GET / 304 18.740 ms - -
    GET / 304 3.950 ms - -
    
  • run the default example test but used my app’s localhost:3000 address:

    const Browser = require('zombie');
    
    // We're going to make requests to http://example.com/signup
    // Which will be routed to our test server localhost:3000
    Browser.localhost('http://localhost:3000/', 3000);
    
    describe('User visits signup page', function() {
    
      const browser = new Browser();
    
      before(function() {
        return browser.visit('/signup');
      });
    
      describe('submits form', function() {
    
        before(function() {
          browser
            .fill('email',    'zombie@underworld.dead')
            .fill('password', 'eat-the-living');
          return browser.pressButton('Sign Me Up!');
        });
    
        it('should be successful', function() {
          browser.assert.success();
        });
    
        it('should see welcome page', function() {
          browser.assert.text('title', 'Welcome To Brains Depot');
        });
      });
    
    });
    
  • same error:

    > mocha test/functional/index.test.js 
    
    
      User visits signup page
        1) "before all" hook
    
    
      0 passing (74ms)
      1 failing
    
      1) User visits signup page "before all" hook:
         TypeError: getaddrinfo ENOTFOUND http http:80
          at node_modules/zombie/lib/pipeline.js:89:15
          at tryCatcher (node_modules/bluebird/js/release/util.js:16:23)
          at Promise._settlePromiseFromHandler (node_modules/bluebird/js/release/promise.js:512:31)
          at Promise._settlePromise (node_modules/bluebird/js/release/promise.js:569:18)
          at Promise._settlePromise0 (node_modules/bluebird/js/release/promise.js:614:10)
          at Promise._settlePromises (node_modules/bluebird/js/release/promise.js:689:18)
          at Async._drainQueue (node_modules/bluebird/js/release/async.js:133:16)
          at Async._drainQueues (node_modules/bluebird/js/release/async.js:143:10)
          at Immediate.Async.drainQueues (node_modules/bluebird/js/release/async.js:17:14)
    

Environment:

  • OSX 10.12.4
  • Node v6.4.0
  • Express v4.15.12
  • Zombie v5.0.5
Read more comments on GitHub >

github_iconTop Results From Across the Web

Fix internet connection problems on Android devices
If you can't access the Internet on your Android device, either through an app or a website, try these troubleshooting steps. Signs of...
Read more >
No Internet Connection? How to Troubleshoot Internet Issues
Is your Wi-Fi connected but you still aren't getting internet? We've put together a guide to help you troubleshoot your network and get...
Read more >
Fix Wi-Fi connection issues in Windows - Microsoft Support
Try these things first to help you fix or narrow down the connection problem. Make sure Wi‑Fi is turned on. Select the "No...
Read more >
Can't Connect to Internet? How to Troubleshoot - Electric AI
Can't Connect to Internet? Here's 9 Ways to Troubleshoot · 1. Check for Physical Connectivity Issues · 2. Restart the Router · 3....
Read more >
13 Tips to Troubleshoot Your Internet Connection | PCMag
If your computer's having problems, see if your tablet or someone else's laptop can connect to the internet. If the problem only happens...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found