kohana/cache — pull request #52 by acoulton (2014-09-19 08:52:07+00:00)
Title: Reinstate and fix skipped cache tests for 3.3

Continuing from #51 and kohana/kohana#50, this pull deals with the large number of currently skipped cache module tests.

It will need a rebase after #51 is merged and travis is active directly on kohana/cache (I have activated on my fork for now). It also breaks at the moment until kohana/core#548 is merged.

**Wincache Driver**

We can't test this on Travis AFAIK and probably won't ever be able to. To reduce noise (so that we can spot unexpected skipped/incomplete tests more easily) I'd like to avoid those tests showing as skipped. I've come up with a hacky workaround here, any better solution would be welcome. Long-term we maybe need to consider whether the wincache driver really belongs here, or in a separate package with its own (windows) test environment - since the combination of rare production usage and no tests running is not good.

**Memcache Driver**

This has some [failing tests on HHVM](https://travis-ci.org/acoulton/cache/jobs/35711321) because of incompatible return types from native memcache methods:

* increment on an undefined key returns 0, not FALSE
* decrement on an undefined key returns 0, not FALSE
* get returns string for integer, float and boolean values (or set stores them incorrectly) - string and array are as expected.

I'll see if I can find any related HHVM issues - increment and decrement we could probably wrap and work around but the return type from get is more tricky. To keep the build green, we may need to convert these HHVM failures into skips in the short term (or configure travis to ignore HHVM as an allowed failure?).