summaryrefslogtreecommitdiffstats
path: root/test
Commit message (Collapse)AuthorAgeFilesLines
...
* Fixing #3668 - fixed autoloading classes from modulesLuke Kanies2010-02-171-197/+0
| | | | | | | | | | | This involved essentially moving all of the importing and loading code out of the Parser and into a new 'TypeLoader' class. The parser and the ResourceTypeCollection classes now delegate to that class for all file handling. Most of the code paths are also now much cleaner, and a bit of redundancy was removed. Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Renamed all references to Reductive Labs to Puppet LabsMarkus Roberts2010-02-171-1/+1
| | | | Find and replace to the rescue...
* Fixing #3533 - Removing all transaction cleanupLuke Kanies2010-02-171-5/+0
| | | | | | | | | | It's really slow and has no actual functionality any more, since we just remove the catalogs from memory anyway. This should be a good speed boost for very little effort. Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Removing obsolete testsLuke Kanies2010-04-121-64/+1
| | | | Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Fixing a warning in the aix package providerLuke Kanies2010-04-121-65/+0
| | | | Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Removing tests for code that was removed in the REST refactorLuke Kanies2010-04-122-302/+0
| | | | Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Fixing and porting Transaction Report testsLuke Kanies2010-04-122-103/+2
| | | | | | | There are still a few unported tests, but it's at least better now. Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Fix test in parser.rb due to API changeJesse Wolfe2010-04-121-1/+1
| | | | Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
* Porting/removing group test/unit testsLuke Kanies2010-04-121-167/+0
| | | | | | | Most of it was just complicated, and the rest useless. Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Porting a simple set of tests from test/unitLuke Kanies2010-04-121-63/+0
| | | | Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Removing obsolete testLuke Kanies2010-04-121-39/+0
| | | | Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Fix a failure in new FileBucket where it was impossible to read from aJesse Wolfe2010-04-091-1/+1
| | | | | | bucket with a non-default path. Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
* Removing any mentions of :casesensitive settingLuke Kanies2010-04-092-164/+0
| | | | | | | | | | | | | | | | | It is a setting that was added years ago as a backward compatibility option and even if it still works, which is questionable, it has no purpose any longer. It just complicated the code and didn't do much, so it's gone now. Also simplified the interface of Leaf#evaluate_match, since it was now using none of the passed-in options. Finally, removed/migrated the last of the Selector/CaseStatement test/unit tests. Signed-off-by: Luke Kanies <luke@puppetlabs.com>
* Finishing renaming :params to :parameters internallyLuke Kanies2010-02-178-158/+22
| | | | | | | | | | | | I had only done this partway, because it seemed easier, but not surprisingly, it ended up being more complex. In addition to those renames, this commit includes fixes to whatever tests I needed to fix to confirm that things were again working. I think most of these broken tests have been broken for a while. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Fixing type/title resource resolutionLuke Kanies2010-02-171-77/+0
| | | | | | | | | | | | | This code is impressively difficult, because sometimes resource types act like resources (classes and nodes are singletons) and sometimes like resource types (defined and builtin resources). So, to get nodes to show as Node[foo] and classes as Class[Foo::Bar], but defined resources to show up as Foo::Bar[baz], we have to do some silliness. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Fixing most of the broken tests in test/Luke Kanies2010-02-1713-492/+86
| | | | | | | | This involves a bit of refactoring in the rest of the code to make it all work, but most of the changes are fixing or removing old tests. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Removing Resource::Reference classesLuke Kanies2010-02-179-799/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit is hopefully less messy than it first appears, but it's certainly cross-cutting. The reason for all of this is that we previously only looked up builtin resource types from outside the parser, but now that the defined resource types are available globally via environments, we can push that lookup code to Resource. Once we do that, however, we have to have environment and namespace information in every resource. Here I remove the Resource::Reference classes (except the AST class), and use Resource instances instead. I did this because the shared code between the two classes got incredibly complicated, such that they should have had a hierarchical relationship disallowed by their constants. This complexity convinced me just to get rid of References entirely. I also make Puppet::Parser::Resource a subclass of Puppet::Resource. There are still broken tests in test/, but this was a big enough commit I wanted to get it in. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Adding parameter validation to Puppet::ResourceLuke Kanies2010-02-172-5/+5
| | | | | | | | | | | | | This will allow us to remove all of the parameter validation from the other Resource classes. This is possible because resource types defined in the language are visible outside of the parser, via the environment. This will enable lots of code removal and simplication. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Feature #3394 REST Runner, preparationJesse Wolfe2010-02-171-1/+1
| | | | Rename Puppet::Agent::Runner to Puppet::Run, for consistency
* Feature #3347 REST-ified FileBucketJesse Wolfe2010-02-172-314/+1
| | | | | | | | | | | | | | | | FileBucket Files have been reimplemented as an indirector terminus so that they can be transmitted over REST. The old Network::Client.dipper has been replaced with a compatibility later in FileBucket::Dipper that uses the indirector to access filebucket termini. Slightly revised patch: * No longer allows nil contents in FileBucket outside of initialization * Uses File.exist? instead of the deprecated File.exists? * Tweaks JSON serialization and de-serialization to include "path" Deferred issues: * Feature #3371 "FileBucket should not keep files in memory". * Feature #3372 "Replace FileBucket Dipper with more idiomatic calls"
* Resolving conflicts with ???Markus Roberts2010-02-173-3/+0
|
* Renaming Parser::ResourceType to Resource::TypeLuke Kanies2010-02-171-3/+3
| | | | | | | | | | Basically, these classes (ResourceType and ResourceTypeCollection) don't really belong in Parser, so I'm moving them to the Resource namespace. This will be where anything RAL-related goes from now on, and as we migrate functionality out of Puppet::Type, it should go here. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Renaming LoadedCode to ResourceTypeCollectionLuke Kanies2010-02-171-3/+3
| | | | Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Removing old, never-used DSL codeLuke Kanies2010-02-171-215/+0
| | | | Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Fix unit tests in file/target.rbJesse Wolfe2010-02-172-2/+2
|
* Name change of event in ral/type/exec.rbJesse Wolfe2010-02-171-1/+1
|
* Use a helper function to evaluate a resource since the API has changedJesse Wolfe2010-02-172-4/+5
|
* Allow skipped resources to process eventsJesse Wolfe2010-02-171-1/+1
|
* Remove test that tests internal class structures which have changed.Jesse Wolfe2010-02-171-28/+0
|
* Remove stale set_triggerJesse Wolfe2010-02-171-97/+0
| | | | | Delete tests that are superceded by specs in "Changing Transaction to use the new ResourceHarness"
* Fix test failures due to name changes of event symbolsJesse Wolfe2010-02-171-4/+4
|
* Remove rollback test, since rollback was removed.Jesse Wolfe2010-02-171-50/+0
|
* Removing now-obsolete user testsLuke Kanies2010-02-171-285/+0
| | | | Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Fixing most failing test/ tests.Luke Kanies2010-02-1710-162/+37
| | | | | | | | | This is mostly just adjusting existing tests to meet new APIs, but it's a small amount of fixing the code to meet new standards and an even smaller amount of porting code over. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Fixing some compatibility and old testsLuke Kanies2010-02-172-92/+4
| | | | | | | We all know these tests should be removed, but hey, at least these ones pass now. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Switching transactions to callback-based eventsLuke Kanies2010-02-172-129/+3
| | | | | | | | | | | | | Events are now queued as they are created, and the queues are managed through simple interfaces, rather than collecting events over time and responding to them inline. This drastically simplifies event management, and will make moving it to a separate system essentially trivial. Signed-off-by: Luke Kanies <luke@madstop.com>
* Some tests were leaking state when the test failedJesse Wolfe2010-02-172-2/+7
|
* Typo in method call in test.Jesse Wolfe2010-02-171-1/+1
|
* Supressing warnings (not really failures) in test/unitJesse Wolfe2010-02-172-9/+19
|
* Fix test using wrong Puppet util filesetting groupRein Henrichs2010-02-171-1/+1
|
* Mock user in SUIDManager testsRein Henrichs2010-02-171-2/+7
|
* Removing resources generate testsRein Henrichs2010-02-171-78/+0
| | | | | | Tests that generating resources performs a check and only returns resources that check as true. There is already spec coverage for this behavior.
* Removing old test for service/debian providerRein Henrichs2010-02-171-58/+0
| | | | it has been superceded by an rspec spec.
* Replace test/unit file write test with specRein Henrichs2010-02-171-21/+0
|
* Fix #2389 - Enhance Puppet DSL with HashesBrice Figureau2010-02-172-0/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This bring a new container syntax to the Puppet DSL: hashes. Hashes are defined like Ruby Hash: { key1 => val1, ... } Hash keys are strings, but hash values can be any possible right values admitted in Puppet DSL (ie function call, variables access...) Currently it is possible: 1) to assign hashes to variable $myhash = { key1 => "myval", key2 => $b } 2) to access hash members (recursively) from a variable containing a hash (works for array too): $myhash = { key => { subkey => "b" }} notice($myhash[key][subjey]] 3) to use hash member access as resource title 4) to use hash in default definition parameter or resource parameter if the type supports it (known for the moment). It is not possible to string interpolate an hash access. If it proves to be an issue it can be added or work-arounded with a string concatenation operator easily. It is not possible to use an hash as a resource title. This might be possible once we support compound resource title. Unlike the proposed syntax in the ticket it is not possible to assign individual hash member (mostly to respect write once nature of variable in puppet). Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
* Merge branch '0.25.x'Markus Roberts2010-02-098-79/+25
|\ | | | | | | | | | | | | | | | | | | Conflicts: lib/puppet/agent.rb lib/puppet/application/puppet.rb lib/puppet/configurer.rb man/man5/puppet.conf.5 spec/integration/defaults.rb spec/unit/configurer.rb
| * Forgot fakedata called in specJames Turnbull2010-02-041-0/+1
| |
| * Minor unit test fixesJames Turnbull2010-01-302-6/+6
| |
| * Fix for #3077 (unit tests broken in 0.25.1-->0.25.4)Markus Roberts2010-01-306-73/+18
| | | | | | | | | | | | Most of these were caused by alias --> host_aliases; one was caused by the canonicalization of resource references and one by the removal of puppet_module.
* | Fixing #1054 - transaction reports are always sentLuke Kanies2010-01-181-44/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | This refactors how reports, catalogs, configurers, and transactions are all related - the Configurer class manages the report, both creating and sending it, so the transaction is now just responsible for adding data to it. I'm still a bit uncomfortable of the coupling between transactions, the report, and configurer, but it's better than it was. This also fixes #2944 and #2973. Signed-off-by: Luke Kanies <luke@madstop.com>