2.0 Unit Tests with XCTest

Another attempt at getting unit tests up and running within the project.

I also wrote several tests around AFSecurityPolicy.

Not all tests have been migrated over, but the old test remain for reference purposes.

Ideally this would get pulled in sooner rather than later to force it to apply unit tests for the remainder of 2.0 development.