Fixing test instrumentation and data manager bug.

Should always check to see that json elements are the type that you think
before using them, or they throw nasty exceptions.
Fixing some racy conditions in Data Manager tests.

It should no longer be possible for data manager tests to get stuck (ie,
very unlikely).
Pulling out some logic from common data manager tests.
Merge pull request #156 from joelkeeling/master

Customized popups
Merge pull request #153 from Mobius5150/fixtests

Fixing issues with Tests
Merge pull request #5 from CMPUT301F14T17/master

merge with master