summaryrefslogtreecommitdiffstats
path: root/spec
Commit message (Collapse)AuthorAgeFilesLines
* (#6612) Changed uptime spec to be endian agnosticAdrien Thebo2011-04-183-1/+6
| | | | | The sysctl uptime fixture was little endian, which fails on sparc hardware. Added a big endian fixture and endian detection.
* refactor the mechanism for allowing for resolution ordering to be influencedRichard Clamp2011-04-062-13/+31
| | | | | renames Facter::Util::Resolution#length to weight as a more generic mechanism for allowing resolutions to state their importance
* Partial fix for #6971 - Fix for virtual testsJames Turnbull2011-04-061-3/+4
|
* Merge remote branch 'adrien/tickets/next/2714' into nextJames Turnbull2011-04-061-3/+5
|\ | | | | | | | | | | * adrien/tickets/next/2714: (#2714) Fixed faulty test (#2714) Added timeout to prtdiag resulution
| * (#2714) Fixed faulty testAdrien Thebo2011-04-011-3/+5
| | | | | | | | | | | | - Looks like some copy/paste added some linux tests that relied on prtdiag, which isn't possible. Corrected them to check against solaris.
| * (#3856) Add virtualbox detection via lspci (graphics card), dmidecode, and ↵Michael Kincaid2011-04-011-0/+27
| | | | | | | | prtdiag for Solaris and corresponding tests. Darwin case is not handled yet.
* | (#5135) Refactored physicalprocessorcountAdrien Thebo2011-04-011-0/+40
| | | | | | | | - Refactored code to make testing simpler
* | (#3856) Add virtualbox detection via lspci (graphics card), dmidecode, and ↵Michael Kincaid2011-04-011-0/+27
|/ | | | prtdiag for Solaris and corresponding tests. Darwin case is not handled yet.
* (#6795) Update tests to reflect changed execJacob Helwig2011-03-211-2/+2
|
* Merge branch 'tickets/next/6716-osx-ipv6-macaddress' into nextJacob Helwig2011-03-174-58/+100
|\ | | | | | | | | | | * tickets/next/6716-osx-ipv6-macaddress: Clean up indentation, and alignment in macaddress_spec.rb (#6716) fix facter issues on OSX with ipv6 in macaddress.rb.
| * Clean up indentation, and alignment in macaddress_spec.rbJacob Helwig2011-03-171-59/+51
| | | | | | | | | | | | | | This changes the spec file from 4-space indentations to 2-space indentations to match the style guide[1]. [1] http://projects.puppetlabs.com/projects/puppet/wiki/Development_Lifecycle#Style
| * (#6716) fix facter issues on OSX with ipv6 in macaddress.rb.Ben Hughes2011-03-174-1/+51
| | | | | | | | | | | | Due to "netstat -rn" returning multiple protocols (IPv4 and IPv6) the "default_interface" can get more than one entry in to it, causing the macaddress resolving to break. This limits it to just one interface.
* | Fixed #2346 - Part 1: Added arp fact for LinuxJames Turnbull2011-03-171-0/+7
| | | | | | | | | | Added facts arp (like the ipaddress etc) facts Added facts arp_interfacename
* | Fixed #3087 - Identify VMWareJames Turnbull2011-03-172-9/+33
| | | | | | | | | | | | | | Added support for VMWareESX and ESXi to operatingsystem and operatingsystemrelease facts Added appropriate tests
* | Merge branch 'tickets/master/6695' into nextJames Turnbull2011-03-171-0/+27
|\ \
| * | Fixed #6695 - Updated id fact for Darwin et alJames Turnbull2011-03-151-0/+27
| |/
* | Fixed #6616 - Spec test failure for vmwareJames Turnbull2011-03-171-2/+4
|\ \
| * | Fixed #6616 - Stubbing in VMware tests on LinuxJames Turnbull2011-03-151-0/+4
| |/
* | (#5011) Adds swap statistics for OSXAdrien Thebo2011-03-151-0/+45
| | | | | | | | | | - Added swapfree and swapsize facts - Tests will now run correctly for osx swap tests
* | Merge branch 'tickets/master/5699' into nextJames Turnbull2011-03-151-2/+18
|\ \
| * | Fixed #5699 - Added virtual support for s390x/ZlinuxJames Turnbull2011-03-071-2/+18
| | | | | | | | | | | | Patch modified from Hector Rivas
* | | Merge branch 'ticket/master/6679' into nextJames Turnbull2011-03-121-6/+6
|\ \ \
| * | | Fix #6679 - Added Scientific Linux to operatingsystem factJames Turnbull2011-03-111-6/+6
| | |/ | |/| | | | | | | Thanks to James Goddard for the patch
* | | Further fix to #5485 - SELinux factsJames Turnbull2011-03-112-2/+34
| | | | | | | | | | | | | | | | | | | | | 1. Added new facts for all values returned by the sestatus command 2. Updated legacy selinux_mode fact with former value 3. Added note and ticket #6677 to remove legacy fact at Facter 2.0.0 4. Added tests for new facts and legacy fact
* | | Merge branch 'tickets/master/6495' into nextJames Turnbull2011-03-092-16/+13
|\ \ \
| * | | Fix for #6495 - Updated interface detectionJames Turnbull2011-03-092-16/+13
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Fixed IP return to not filter lo/localhost and return it as a proper interface 2. Fixed HP-UX netstat return to remove extraneous first line of naming. 3. Updated tests to reflect changes
* / / Fixed #5485 - Updated selinux_mode factJames Turnbull2011-03-092-2/+17
|/ / | | | | | | | | | | 1. Added tested 2. Refactored to use F:U:R.exec 3. Chomp trailing newline
* / (#6615) fix missing stub calls in loader specsRick Bradley2011-03-071-2/+9
|/ | | | | | | | | | It's not clear to me how these are now needed and apparently weren't when we first checked this in. These stubs will let the specs continue on so we can check the load order, which was the original intent of (#5510) which caused the introduction of these specs. Signed-off-by: Rick Bradley <rick@rickbradley.com>
* Fixed #6611 - Fixed broken HPVM test and rationalised test structureJames Turnbull2011-03-071-15/+8
|
* Merge branch 'tickets/master/6525'James Turnbull2011-03-071-2/+2
|\
| * Fixed #6525 - Test failures on Ruby 1.9.xJames Turnbull2011-03-021-2/+2
| |
* | (#2270) add testing for the new ipaddress6 featureDaniel Pittman2011-02-175-0/+106
| | | | | | | | | | | | | | | | This stubs out the platform side of the code, and uses fixtures emitting the right output from the interface configuration tools. Paired-With: Matt Robinson <matt@puppetlabs.com> Paired-With: Max Martin <max@puppetlabs.com>
* | (#6360) Flush Facter top level cache before every test case.Daniel Pittman2011-02-171-1/+6
|/ | | | | | | | This adds a suite-wide "Facter.clear" call before :each test case to ensure that we can't accidentally cache data when we are invoked using top level Facter interfaces to get at data. Paired-with: Jacob Helwig <jacob@puppetlabs.com>
* Fix #4755: add support for GNU/kFreeBSD platform where missing.Marc Fournier2011-01-313-3/+73
| | | | | | | | | Merged manually to the current state of the art. Minimal conflicts resolved by adding both Darwin and GNU/KFreeBSD to the confine lines. Author: Marc Fournier <marc.fournier@camptocamp.com> Signed-off-by: Daniel Pittman <daniel@puppetlabs.com> Signed-off-by: Rick Bradley <rick@rickbradley.com>
* (#5510) Facter should load custom fact definitions in filename order.Rick Bradley2011-01-311-0/+43
| | | | | | | | | | | | | | | | Ruby's Dir.entries will return files in different orders depending on the OS and/or filesystem. As a result Facter::Util::Loader will load ruby custom fact definitions in different orders on different platforms. Specs to expose the bugs, and code to ensure that custom fact files are loaded in alphabetical order. Addresses redmine issue #5510 http://projects.puppetlabs.com/issues/5510 Signed-off-by: Rick Bradley <rick@rickbradley.com> Signed-off-by: Daniel Pittman <daniel@puppetlabs.com>
* Refactor #6044 -- use _spec.rb as the pattern for spec tests.Daniel Pittman2011-01-2721-0/+0
| | | | | | Rename all the spec tests to follow the rspec convention of *_spec.rb rather than unadorned *.rb; this also makes it easier to work with them consistently without using the Rakefile support that customizes that.
* Refactor #6044 -- require spec_helper with a consistent path.Daniel Pittman2011-01-2721-21/+21
| | | | | | Because we pull in spec_helper in individual tests, we need to use a consistent path or Ruby will evaluate it multiple times. Make the path consistent by expanding it before require.
* Refactor #6044 -- port testing to rspec2Daniel Pittman2011-01-278-36/+18
| | | | We have moved to rspec2 for puppet, and facter should follow suit.
* (#5086) Try using kstat before falling back to 'who -b' to determine uptime.Jacob Helwig2011-01-242-8/+22
| | | | | | | | | 'who -b' doesn't report the year of the last system boot on (at least) Solaris 10, and OpenSolaris 2009.06. Try using 'kstat -p unix:::boot_time', which reports as seconds since the epoch on these systems before falling back to 'who -b'. Reviewed-by: Paul Berry <paul@puppetlabs.com>
* Refactor util/uptime.rb tests to reduce duplication using contextsJacob Helwig2011-01-241-27/+34
| | | | Reviewed-by: Paul Berry <paul@puppetlabs.com>
* (#4754) Change is_virtual logic to not enumerate virtual typesMatt Robinson2010-11-301-0/+6
| | | | | | | | While looking at the patch for adding parallels to the virtual types David Schmitt noticed that it might be easier just to list the types that are NOT virtual since there's fewer of them. Paired-with: Nick Lewis
* (#4754) Add support for Darwin and Parallels VM to "virtual" factDonavan Miller2010-11-301-0/+91
| | | | | | | | | | | | | Adds support for Parallels VM guest detection with existing operating systems. Detects Parallels based on hardware vendor name and pci id. The Parallels vendor id does not seem to be listed in most pci.ids. Adds resolution for "virtual" fact in the Darwin kernel. This uses the existing Facter::Util::Macosx module to resolve system profiler data. Both vendor name and vendor id values are checked. Resolution appears to vary based on VM Host product. Signed-off-by: donavanm <donavan@desinc.net>
* (#5325) Add tests for SPARC manufacturer and product nameMatt Robinson2010-11-221-1/+12
| | | | | | | Just tests the regex, won't actually catch problems if prtdiag doesn't return output like our test. Paired-with: Nick Lewis
* maint: Fix spec failures caused by having a space in the path to facter's sourceNick Lewis2010-11-222-6/+6
|
* (#4989) Add xendomains factRein Henrichs2010-11-092-0/+27
| | | | | Parses `/usr/sbin/xm list` and returns a comma-separated list of domains. Based on a patch submitted by Jonas Genannt.
* Merge remote branch 'stschulte/feature/master/5040' into nextPaul Berry2010-11-092-0/+22
|\ | | | | | | | | | | Manually resolved conflicts: lib/facter/virtual.rb spec/unit/virtual.rb
| * (#5040) fact virtual should detect hpvmStefan Schulte2010-11-032-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With HP-UX you can build virtual machines that are often refered to as HP-VMs. This patch detecs HP-VMs by introducing a new function hpvm? that will check the output of /usr/bin/getconf MACHINE_MODEL. This should not depend on any tools that might be not installed. If inside a HP-VM the command will say something like ia64 hp server Integrity Virtual Machine while on real hardware the output could be ia64 hp server rx660 so searching for "Virtual Machine" should work. Currently it only works if the guest is also running HP-UX. (I guess this is the most common usecase).
* | Merge remote branch 'stschulte/ticket/master/5016' into nextPaul Berry2010-11-091-0/+6
|\ \ | | | | | | | | | | | | | | | Manually resolved conflicts: lib/facter/virtual.rb spec/unit/virtual.rb
| * | (#5016) is_virtual should be true on solaris zonesStefan Schulte2010-11-031-0/+6
| |/ | | | | | | | | | | | | While the fact virtual recognised solaris zones before, the is_virtual fact did not. With this patch applied is_virtual returns true on (non-global) zones
| |
| \
*-. \ Merge remote branches 'pnasrat/tickets/master/4889' and ↵Rein Henrichs2010-10-182-6/+7
|\ \ \ | | | | | | | | | | | | 'pnasrat/tickets/master/4956' into next