Skip to content

Instantly share code, notes, and snippets.

@Iristyle
Created July 13, 2018 18:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Iristyle/6d88d748b4d9e163ee80d2ee42d7b066 to your computer and use it in GitHub Desktop.
Save Iristyle/6d88d748b4d9e163ee80d2ee42d7b066 to your computer and use it in GitHub Desktop.
Puppet::Util::Platform.windows? vs Puppet.features.microsoft_windows?

So we have 2 mechanisms that we use to check whether or not we're on Windows.

In this particular instance, I think we'd prefer to use Puppet::Util::Platform.windows? as I wouldn't expect any cross-platform stubbing to occur in tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment