Setting the owner of the database with createdb.
Convert system tests to use rspec-system

This patch ports all of the existing system tests to use rspec-system instead.

To assist with this conversion some patches were made to fix OS compatibility
where necessary. We also added an ensure parameter to the postgresql::server
class to assist with removing PostgreSQL configuration to aid with testing
cleanups.

The documentation has been updated to indicate test usage with rspec-system,
we've also renamed the 'tests' directory to 'examples'.

Signed-off-by: Ken Barber <ken@bob.sh>
Merge pull request #186 from kbarber/rspec-system-conversion

Convert system tests to use rspec-system
Add support for other operating systems besides Redhat/Debian

Prior to this commit, if you attempted to use the module to
manage postgres on any OS other than Redhat/Debian, there
was an explicit check for that, and a call to `fail`.

In reality, the OS family is only used to build up defaults
for various path and package names, which are all exposed
as parameters.  If the user is willing to explicitly pass
in all of those parameters, there's no reason we should
fail based on OS family.

This commit adds checks to the 'default' osfamily case
such that we now only fail if they're on a non-Redhat-or-Debian
system *and* they haven't explicitly passed in values for
all of the required parameters.
Fix up and add some tests for unknown OS patch

This patch just adds some new tests for the unknown OS patch, and cleans up
some existing tests to look for the new warning message.

Also, change the warning message for $osfamily and manage_package_repo to
reflect the parameter at fault.

Signed-off-by: Ken Barber <ken@bob.sh>
Don't hard-code postgres user's username for pg_hba
Merge pull request #189 from kbarber/feature/master/support-more-distroz

Add more distributions
Merge pull request #188 from cprice-puppet/bug/master/fix-hard-coded-postgres-user-in-hba

Don't hard-code postgres user's username for pg_hba
Merge pull request #156 from harbulot/issue_114

Setting the owner of the database with createdb.
Update docs to reflect new `owner` parameter for `::database` type.
Update Modulefile and Changelog for 2.3.0 release
Merge pull request #190 from cprice-puppet/maint/master/docs-for-database-owner

Update docs to reflect new `owner` parameter for `::database` type.
Merge pull request #191 from cprice-puppet/maint/master/release-2.3.0

Update Modulefile and Changelog for 2.3.0 release
Rename role_spec.pp to role_spec.rb
Rename tablespace_spec.pp to tablespace_spec.rb
Include location in postgresql::tablespace test

Signed-off-by: Ken Barber <ken@bob.sh>
Fix travis.yml

Signed-off-by: Ken Barber <ken@bob.sh>
Merge branch 'rename_test_files'

* rename_test_files:
  Fix travis.yml
  Include location in postgresql::tablespace test
  Rename tablespace_spec.pp to tablespace_spec.rb
  Rename role_spec.pp to role_spec.rb
Fix the non-defaults test failing to use UTF8

The non-default tests try to set UTF8 when UTF8 is not installed on the en_US
machine. These are non-default settings anyway, but one should presume the
correct locale should be set before this is attempted, this patch includes
that step.

In an ideal world we would use a locale module to do this.

This patch also fixes an Ubuntu 10.04 issue where you need to be absolute about
the locale and encoding as well.

Signed-off-by: Ken Barber <ken@bob.sh>
Merge pull request #194 from kbarber/fixed_failing_utf8_tests

Fix the non-defaults test failing to use UTF8