Add "Coverage" configuration with code coverage flags set.

- new build settings
- integration with Coveralls.io when using Travis CI
- workarounds for Apple bugs

"Coverage" config is based on "Debug" but enables "Generate Test Coverage
Files" and "Instrument Program Flow" for builds. Unit tests use
this configuration now instead of Debug and also set a COVERAGE=1 flag,
for conditional use in the code.

.gcda and .gcno files are now generated, and live in
~/Library/Developer/Xcode/DerivedData/SPDY-fkxxegoemtsttmayyuvejarxgimy/Build/Intermediates/SPDY.build/Coverage-iphonesimulator/SPDYUnitTests.build/Objects-normal/i386

They can be opened with something like CoverStory locally after running
the unit tests. On Github, our integration with Travis will produce
Coveralls data for pull requests and inserts a little coverage badge.

The Travis build uses the cpp-coverage utility (coveralls) to produce
reports for Coveralls.io ingestion. This tool requires the source code and
the coverage files to be located under a common root, hence the copy into
the "gcov" directory. Finding the location where Xcode puts the
intermediate files is non-trivial, so we take advantage of the fact
Travis gives us a clean slate each time.

SPDYSenTestLog.m is created to workaround a bug where no .gcda files
are generated for certain combinations unless they are explicitly
flushed. It's unclear exactly when this happens, but simulator 7.0 is
affected, and simulator 8.0 with Travis is affected.
Merge pull request #86 from kgoodier/feature/code-coverage

Add "Coverage" configuration with code coverage flags set.
Avoid use of CFAbsoluteTime as much as possible.

A helper class SPDYStopwatch is introduced here to abstract common
time management duties from the rest of the code.

Since CFAbsoluteTimeGetCurrent() is affected by clock and timezone
changes, it's use should be avoided. mach_absolute_time() is unaffected
by clock changes, but is susceptible to overflow issues (which can be
worked around) and doesn't increment while the system is asleep (which
cannot be worked around). However, it has more appropriate behavior.

Our use of CFAbsoluteTimeGetCurrent() for the timers is unavoidable,
since Cocoa timers are based on it. This seems like it would present
undesirable behavior for our deferrable and connect timers if the clock
were to change, but there's not much to do about it.
Support "absolute time" for measurements and revert.

After discussion, we decided to revert back to using CFAbsoluteTime for
timing operations. There are pros and cons of each approach, and it
boiled down to basically "keep doing what we were doing since it wasn't
obviously broken". This will keep the metadata timing values consistent.

The things being measured -- latency, connected time -- are really
wall-time measurements, and having them affected by sleep time is odd.
Merge pull request #87 from kgoodier/review/absolute-time

Avoid use of CFAbsoluteTime as much as possible.
Fix early release of SPDYMetadata.

Depending on how the NSURL loading system deallocs the protocol,
the SPDYMetadata could be released before the didFinishLoading callback
even executed, or in the middle of it. It seems that iOS 8 releases
the protocol earlier than iOS 7 did.

This change removes all the dictionary code to map identifiers to
SPDYMetadata instances and instead just associates the metadata instance
with the identifier instance. A unique identifier instance is returned
for each associated dictionary it is insert into.

As long as the NSString* identifier is alive, the SPDYMetadata for it
will also be alive.
Merge pull request #84 from kgoodier/develop-next

Fix early release of SPDYMetadata.
Remove .gcda files to prevent "invalid arc tag" warnings.
Remove bogus SPDYProtocol assert.

We do, in fact, write 0 bytes. Sometimes the final data frame is
simply a marker for "end of stream" but has no body, and the SPDYSession
code doesn't check for this case.
Minor public API changes for logging and metadata.

Add currentLogger method.
Add currentLoggerLevel method.
Return nil instead of an empty dictionary when metadata not available.
Expose SPDYError.h as a public header.

Split out the helper macros into SPDYDefinitions.h, and clean up
internal usage of the headers.

Also moves SPDYError.h to the "public" headers in Xcode.
Merge pull request #88 from kgoodier/develop-next

Minor public api and cleanup changes.
Fix non-retained hostAddress in metadata.

hostAddress in SPDYMetadata had a typo and was using "assign" instead
of either "retain" or "copy". This could lead to crashes.

Also update all properties to be "nonatomic" and NSStrings "copy".
Fix redirects inside a WebView.

[NSURL initWithString:relativeToURL] produces odd results. The
URLs do not compare unless you examine the absolute strings, and when
going through a WebView on iOS8 the entire host gets stripped off. This
is not the case with iOS7. This fixes it by constructing a second NSURL
for the redirect based on the absolute string.

In addition, a 302 should behave like a 303 in that it rewrites a POST
as a GET. This is undefined in the HTTP spec but many user agents do
this, including it seems Apple's own in its HTTP stack as used by a
WebView. This was observed with Charles proxy, so this change makes
CocoaSPDY behave the same way.

Finally, when redirecting from a POST to a GET, the content-length and
content-type headers need to be stripped, as do all forms of body
content. Those headers are added automatically during canonicalization.
"SPDY", not "SDPY".
Merge pull request #90 from kgoodier/develop-next

Fix redirects and unretained metadata property.
Merge branch 'develop' into review/http-proxy

* develop:
  "SPDY", not "SDPY".
  Fix redirects inside a WebView.
  Fix non-retained hostAddress in metadata.
  Expose SPDYError.h as a public header.
  Minor public API changes for logging and metadata.
  Remove bogus SPDYProtocol assert.
  Remove .gcda files to prevent "invalid arc tag" warnings.
  Fix early release of SPDYMetadata.
  Support "absolute time" for measurements and revert.
  Avoid use of CFAbsoluteTime as much as possible.
  Add "Coverage" configuration with code coverage flags set.

Conflicts:
	SPDY.xcodeproj/project.pbxproj
	SPDY/SPDYSession.m
	SPDY/SPDYSocket.m