On 2 November 2016 at 18:10, Gavin Williams <fatmc...@gmail.com> wrote:
> Stephen > > If you're already using R10k or Librarian-Puppet, as indicated by the > Puppetfile, then it should be possible to simplify that... > > For example, my .fixtures.yml looks like: > -- > fixtures: > symlinks: > [module_name]: "#{source_dir}" > > > With the latest puppetlabs_spec_helper versions you can even leave that out. See the first example at https://github.com/puppetlabs/puppetlabs_spec_helper#fixtures-examples > Puppetfile: > #!/usr/bin/env ruby > > forge 'http://forge.puppetlabs.com' > > metadata > > # mod 'puppet-archive', > # :git => 'https://github.com/fatmcgav/puppet-archive.git', > # :ref => 'support-1.8.7-puppet4' > > > The Puppetfile above pulls a list of required modules from your > metadata.json file, and Librarian-Puppet takes care of installing and > resolving deps... > > Rakefile addition: > # use librarian-puppet to manage fixtures instead of .fixtures.yml > # offers more possibilities like explicit version management, forge > downloads,... > task :librarian_spec_prep do > sh "librarian-puppet install --path=spec/fixtures/modules/" > end > task :spec_prep => :librarian_spec_prep > task :librarian_clean do > sh "librarian-puppet clean" > end > > Nifty! I guess the same can be used in the acceptance tests if necessary. the one gap (that is also not addressed by any other current tooling) is if you have different testing requirements for different environments (e.g. validate production, vs. smoke-testing upstream versions pre-upgrade. Thanks a lot for sharing! d. > > > HTH > Gav > > > On Wednesday, 2 November 2016 16:41:03 UTC, Stephen Nesbitt wrote: >> >> Garrett - Thanks for the heads up! >> >> David - thanks for the comment! >> >> I will note that I am now maintaining dependency information in 3 >> locations - Puppetfile, metdata.json and .fixtures, Guess what is going to >> happen at some point ;-) >> >> Maybe I'm not aware of something, but there really should be a single >> canonical source of dependency requirements. >> >> -steve >> >> On Wednesday, November 2, 2016 at 6:55:05 AM UTC-7, David Schmitt wrote: >>> >>> >>> >>> On Tuesday, November 1, 2016 at 7:25:01 PM UTC, Garrett Honeycutt wrote: >>> >>>> I noticed that your .fixtures.yml do not include versions. This means >>>> that they will always test against the latest version. You probably >>>> want >>>> to change this to use the version you actually use. >>>> >>> >>> That really depends on the amount of time and the cadence people are >>> willing to invest in staying up-to-date. Shops with strict version >>> requirements and a waterfall-y workflow really should do that. Others with >>> a more fluid/agile/pipeline-oriented workflow are much better suited to >>> address upcomping changes when they happen, instead of batching it up. >>> >>> Cheers, D. >>> >>> >> -- > You received this message because you are subscribed to a topic in the > Google Groups "Puppet Users" group. > To unsubscribe from this topic, visit https://groups.google.com/d/ > topic/puppet-users/ph6_kdzr0Ec/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > puppet-users+unsubscr...@googlegroups.com. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/puppet-users/e546756d-b24d-417c-9d78-0d8162210edc%40googlegroups.com > <https://groups.google.com/d/msgid/puppet-users/e546756d-b24d-417c-9d78-0d8162210edc%40googlegroups.com?utm_medium=email&utm_source=footer> > . > > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CALF7fHbr%3DwXRrAHWoYSvPz3Vtx_2SiGzRaxpeKTTr4F5GBEu5w%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.