Don't set all injector instances to the global instance.
FIX: Only unregister the relevant class when adding an extension.

This fixes an issue where the Config instance could not be injected, as
it would be immediately cleared.
BUG Default Member.Locale now chooses a better default value when i18n.locale is not a valid translation

This will resolve issues in cases where the site locale may be assigned a value that does not have an explicit translation. E.g. if the locale is en_NZ (and it's appropriate for this to be the assigned locale), Afrikaans will no longer be the default selected locale when creating members. Now en_US is chosen as a better fallback default.

This is a minor ease of use fix that means fewer CMS users can be accidentally created in Afrikaans within NZ based sites.

Test cases included.
Don't show next for anything above TotalPages

Bots often have the habit of trying a next page, even if there isn't one.
Thus, using CurrentPage < TotalPages, prevents from unwanted next-links being shown.
NEW: Allow specifying a factory to use for creating services.

A service factory can be used for creating instances where a non-trivial
construction process is required. This is done by adding a `factory`
key to the service definition.
Register config as a service.
Merge pull request #2815 from Firesphere/patch-2

Don't show next for anything above TotalPages
Support PHPUnit 3.8+ compatibility

Summary:

PHPUnit 3.8+ adds a method to its PHPUnit_Framework_TestListener called addRiskyTest(). Need to stub it out to avoid "must implement this interface method" fatals when using 3.8+

Test Plan:

Reviewers:

CC:

Task ID: #

Blame Rev:
Merge pull request #2819 from JoelMarcey/3.1

Support PHPUnit 3.8+ compatibility
Merge pull request #2700 from ajshort/injector-factory

Injector Factory
Merge pull request #2806 from tractorcow/pulls/bug-member-locale

BUG Default Member.Locale now chooses a better default value when i18n.locale is not a valid translation