Add test infrastructure

It's about time we had a testsuite! For now, it uses only a very basic,
ad-hoc test framework, but it works!
tests/runTest: Allow tests to return Pass, Fail, and Skip voluntarily

Rather than decoding the status value, sometimes it is more convenient
to have tests return the Pass/Fail/Skip result directly.
test: Allow tests to probe whether they have an authenticated session

Sometimes, a test should only run with an authenticated (or anonymous)
session. In these cases, the test needs a way to test for this, and
Skip if the proper condition isn't met.
test: New test test_userrepos

The first authenticated-only test
test/init*Session: Instantiate arbitrary API subclasses

Github isn't the only valid API class now, and we need to test others as
well.