mozilla/browserid — Issue #1171: phantom js tests blow up after calling set_password
Author: shane-tomlinson
Created: 2012-02-22 11:33:28+00:00
State: open

STR:

1) Start up browserid server.
2) from the resources/static/test directory, run `phantomjs ./phantomrunner.js /test/`
3) Wait for about a minute.
4) Watch several "SyntaxError: Unable to parse JSON string"s pass by.
5) Watch "Bus error: 10" be thrown

Log from PhantomJS console:

````
[11:30][test(dev)] $ phantomjs ./phantomrunner.js http://127.0.0.1:10002/test/
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
SyntaxError: Unable to parse JSON string
Bus error: 10
[11:31][test(dev)] $
````

Log from BrowserID console:

````
[11:30][browserid_private(prod)] $ npm start

> browserid@0.0.1 start /Users/stomlinson/development/browserid_private
> ./scripts/run_locally.js

The "sys" module is now called "util". It should have a similar interface.
spawned verifier (/Users/stomlinson/development/browserid_private/bin/verifier) with pid 28086
info: process type is run_locally
verifier (28086): The "sys" module is now called "util". It should have a similar interface.
verifier (28086): info: verifier server starting up
verifier (28086): info: process type is verifier
verifier (28086): info: running on http://127.0.0.1:10000
spawned keysigner (/Users/stomlinson/development/browserid_private/bin/keysigner) with pid 28087
keysigner (28087): The "sys" module is now called "util". It should have a similar interface.
keysigner (28087): info: process type is keysigner
keysigner (28087): info: running on http://127.0.0.1:10003
spawned dbwriter (/Users/stomlinson/development/browserid_private/bin/dbwriter) with pid 28088
dbwriter (28088): The "sys" module is now called "util". It should have a similar interface.
dbwriter (28088): info: dbwriter starting up
dbwriter (28088): inserted primary info for 'example.domain' into cache, pointed at 'http://127.0.0.1:10005'
dbwriter (28088): debug: domain key was created at Wed Feb 22 2012 10:44:14 GMT+0000 (GMT) (certs issued prior to this are bogus)
dbwriter (28088): debug: WSAPIs:
dbwriter (28088): debug: account_cancel (POST - authed)
dbwriter (28088): debug: add_email_with_assertion (POST - authed - assertion)
dbwriter (28088): debug: complete_email_addition (POST - not authed - token)
dbwriter (28088): debug: complete_user_creation (POST - not authed - token, pass)
dbwriter (28088): debug: create_account_with_assertion (POST - not authed - assertion)
dbwriter (28088): debug: remove_email (POST - authed - email)
dbwriter (28088): debug: stage_email (POST - authed - email, site)
dbwriter (28088): debug: stage_user (POST - not authed - email, site)
dbwriter (28088): debug: update_password (POST - authed - oldpass, newpass)
dbwriter (28088): debug: opening JSON database: /Users/stomlinson/development/browserid_private/var/authdb.json
dbwriter (28088): debug: Database doesn't exist (yet): /Users/stomlinson/development/browserid_private/var/authdb.json
dbwriter (28088): info: process type is dbwriter
dbwriter (28088): info: running on http://127.0.0.1:10004
spawned example (/Users/stomlinson/development/browserid_private/scripts/serve_example.js) with pid 28089
example (28089): using browserid server at http://127.0.0.1:10002
example (28089): running on http://127.0.0.1:10001
spawned example_primary (/Users/stomlinson/development/browserid_private/scripts/serve_example_primary.js) with pid 28090
example_primary (28090): using browserid server at http://127.0.0.1:10002
example_primary (28090): running on http://127.0.0.1:10005
spawned browserid (/Users/stomlinson/development/browserid_private/bin/browserid) with pid 28091
browserid (28091): The "sys" module is now called "util". It should have a similar interface.
browserid (28091): info: browserid server starting up
browserid (28091): inserted primary info for 'example.domain' into cache, pointed at 'http://127.0.0.1:10005'
browserid (28091): debug: domain key was created at Wed Feb 22 2012 10:44:14 GMT+0000 (GMT) (certs issued prior to this are bogus)
browserid (28091): debug: WSAPIs:
browserid (28091): debug: address_info (GET - not authed - email)
browserid (28091): debug: auth_with_assertion (POST - not authed - assertion)
browserid (28091): debug: authenticate_user (POST - not authed - email, pass)
browserid (28091): debug: cert_key (POST - authed - email, pubkey)
browserid (28091): debug: email_addition_status (GET - authed - email)
browserid (28091): debug: email_for_token (GET - not authed - token)
browserid (28091): debug: have_email (GET - not authed - email)
browserid (28091): debug: list_emails (GET - authed)
browserid (28091): debug: logout (POST - authed)
browserid (28091): debug: session_context (GET - not authed)
browserid (28091): debug: user_creation_status (GET - not authed - email)
browserid (28091): debug: forwarded WSAPIs (to http://127.0.0.1:10004/):
browserid (28091): debug: account_cancel (POST - not authed)
browserid (28091): debug: add_email_with_assertion (POST - not authed)
browserid (28091): debug: complete_email_addition (POST - not authed)
browserid (28091): debug: complete_user_creation (POST - not authed)
browserid (28091): debug: create_account_with_assertion (POST - not authed - assertion)
browserid (28091): debug: remove_email (POST - not authed)
browserid (28091): debug: stage_email (POST - not authed)
browserid (28091): debug: stage_user (POST - not authed)
browserid (28091): debug: update_password (POST - not authed)
browserid (28091): debug: opening JSON database: /Users/stomlinson/development/browserid_private/var/authdb.json
browserid (28091): debug: Database doesn't exist (yet): /Users/stomlinson/development/browserid_private/var/authdb.json
browserid (28091): info: process type is browserid
browserid (28091): info: running on http://127.0.0.1:10002
browserid (28091): info: GET /test/ 200 2ms
browserid (28091): info: GET /test/qunit.css 200 2ms
browserid (28091): info: GET /test/qunit.js 200 2ms
browserid (28091): info: GET /include.js 200 2ms
browserid (28091): info: GET /lib/ejs.js 200 3ms
browserid (28091): info: GET /lib/underscore-min.js 200 2ms
browserid (28091): info: GET /lib/jquery-1.7.1.min.js 200 15ms
browserid (28091): info: GET /lib/vepbundle.js 200 18ms
browserid (28091): info: GET /shared/browserid.js 200 4ms
browserid (28091): info: GET /lib/dom-jquery.js 200 4ms
browserid (28091): info: GET /lib/module.js 200 3ms
browserid (28091): info: GET /lib/hub.js 200 4ms
browserid (28091): info: GET /lib/jschannel.js 200 1ms
browserid (28091): info: GET /test/qunit/mocks/mocks.js 200 2ms
browserid (28091): info: GET /shared/javascript-extensions.js 200 2ms
browserid (28091): info: GET /test/qunit/mocks/provisioning.js 200 2ms
browserid (28091): info: GET /test/qunit/mocks/templates.js 200 2ms
browserid (28091): info: GET /test/qunit/mocks/xhr.js 200 2ms
browserid (28091): info: GET /test/qunit/mocks/window.js 200 1ms
browserid (28091): info: GET /shared/renderer.js 200 3ms
browserid (28091): info: GET /test/qunit/mocks/winchan.js 200 2ms
browserid (28091): info: GET /shared/screens.js 200 2ms
browserid (28091): info: GET /shared/mediator.js 200 2ms
browserid (28091): info: GET /shared/class.js 200 3ms
browserid (28091): info: GET /shared/browser-support.js 200 2ms
browserid (28091): info: GET /shared/error-display.js 200 1ms
browserid (28091): info: GET /shared/error-messages.js 200 1ms
browserid (28091): info: GET /shared/wait-messages.js 200 4ms
browserid (28091): info: GET /shared/network.js 200 3ms
browserid (28091): info: GET /shared/storage.js 200 4ms
browserid (28091): info: GET /shared/tooltip.js 200 1ms
browserid (28091): info: GET /shared/provisioning.js 200 1ms
browserid (28091): info: GET /shared/user.js 200 2ms
browserid (28091): info: GET /shared/validation.js 200 1ms
browserid (28091): info: GET /dialog/resources/internal_api.js 200 0ms
browserid (28091): info: GET /shared/helpers.js 200 1ms
browserid (28091): info: GET /dialog/resources/state_machine.js 200 1ms
browserid (28091): info: GET /dialog/resources/helpers.js 200 1ms
browserid (28091): info: GET /dialog/controllers/page.js 200 0ms
browserid (28091): info: GET /dialog/controllers/code_check.js 200 1ms
browserid (28091): info: GET /dialog/controllers/actions.js 200 1ms
browserid (28091): info: GET /dialog/controllers/add_email.js 200 0ms
browserid (28091): info: GET /dialog/controllers/dialog.js 200 0ms
browserid (28091): info: GET /dialog/controllers/pick_email.js 200 0ms
browserid (28091): info: GET /dialog/controllers/check_registration.js 200 1ms
browserid (28091): info: GET /dialog/controllers/authenticate.js 200 0ms
browserid (28091): info: GET /dialog/controllers/required_email.js 200 1ms
browserid (28091): info: GET /dialog/controllers/verify_primary_user.js 200 1ms
browserid (28091): info: GET /dialog/controllers/forgot_password.js 200 6ms
browserid (28091): info: GET /pages/page_helpers.js 200 2ms
browserid (28091): info: GET /dialog/controllers/set_password.js 200 2ms
browserid (28091): info: GET /dialog/controllers/primary_user_provisioned.js 200 2ms
browserid (28091): info: GET /dialog/controllers/provision_primary_user.js 200 2ms
browserid (28091): info: GET /dialog/controllers/email_chosen.js 200 1ms
browserid (28091): info: GET /pages/add_email_address.js 200 1ms
browserid (28091): info: GET /pages/forgot.js 200 1ms
browserid (28091): info: GET /pages/signup.js 200 2ms
browserid (28091): info: GET /pages/signin.js 200 2ms
browserid (28091): info: GET /pages/manage_account.js 200 1ms
browserid (28091): info: GET /pages/verify_email_address.js 200 1ms
browserid (28091): info: GET /test/qunit/pages/browserid_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/testHelpers/helpers.js 200 3ms
browserid (28091): info: GET /test/qunit/include_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/pages/verify_email_address_test.js 200 2ms
browserid (28091): info: GET /test/qunit/pages/add_email_address_test.js 200 2ms
browserid (28091): info: GET /test/qunit/pages/page_helpers_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/pages/forgot_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/pages/manage_account_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/pages/signup_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/pages/signin_unit_test.js 200 10ms
browserid (28091): info: GET /test/qunit/shared/renderer_unit_test.js 200 3ms
browserid (28091): info: GET /test/qunit/shared/helpers_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/shared/error-display_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/shared/tooltip_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/shared/screens_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/shared/storage_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/shared/validation_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/shared/browser-support_unit_test.js 200 0ms
browserid (28091): info: GET /test/qunit/shared/network_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/shared/user_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/resources/helpers_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/resources/internal_api_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/resources/state_machine_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/controllers/page_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/controllers/add_email_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/controllers/pick_email_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/controllers/code_check_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/actions_unit_test.js 200 2ms
browserid (28091): info: GET /test/qunit/controllers/authenticate_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/check_registration_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/verify_primary_user_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/required_email_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/forgot_password_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/email_chosen_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/provision_primary_user_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/primary_user_provisioned_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/dialog_unit_test.js 200 1ms
browserid (28091): info: GET /test/qunit/controllers/set_password_unit_test.js 200 1ms
browserid (28091): info: GET /dialog/views/site/signup.ejs 200 1ms
browserid (28091): info: GET /dialog/views/error.ejs 200 2ms
browserid (28091): info: GET /dialog/views/site/add_email_address.ejs 200 0ms
browserid (28091): info: GET /dialog/views/tooltip.ejs 200 1ms
browserid (28091): info: GET /dialog/views/site/verify_email_address.ejs 200 2ms
browserid (28091): info: GET /dialog/views/site/forgot.ejs 200 0ms
browserid (28091): info: GET /dialog/views/site/signin.ejs 200 1ms
browserid (28091): info: GET /dialog/views/site/index.ejs 200 0ms
browserid (28091): info: GET /i/slit.png 200 0ms
browserid (28091): info: GET /i/slit.png 304 0ms
browserid (28091): info: GET /dialog/views/testBodyTemplate.ejs 200 1ms
browserid (28091): info: GET /dialog/views/wait.ejs 200 2ms
browserid (28091): info: GET /dialog/production_vABC123.js 404 1ms
browserid (28091): info: GET /dialog/views/invalid_required_email.ejs 200 1ms
browserid (28091): info: GET /dialog/views/offline.ejs 200 1ms
browserid (28091): info: GET /dialog/views/pick_email.ejs 200 0ms
browserid (28091): info: GET /dialog/views/add_email.ejs 200 2ms
browserid (28091): info: GET /dialog/views/confirm_email.ejs 200 2ms
browserid (28091): info: GET /dialog/views/authenticate.ejs 200 1ms
browserid (28091): info: GET /dialog/views/forgot_password.ejs 200 0ms
browserid (28091): info: GET /dialog/views/required_email.ejs 200 1ms
browserid (28091): info: GET /dialog/views/verify_primary_user.ejs 200 3ms
browserid (28091): info: GET /dialog/views/primary_user_verified.ejs 200 1ms
browserid (28091): info: GET /dialog/views/set_password.ejs 200 0ms
````