functions/private/Test-Dependencies.ps1

function Test-Dependencies {
  <#
  .SYNOPSIS
  Ensures the dependencies for this PowerShell module are in place before importing is successful.
  #>

  [CmdletBinding()]
  param (
  )

  if (-not (Get-Command -Name 7z)) {
    Write-Error -Message 'Please ensure 7-zip is installed and can be called with "7z" to import this module.'
  }
}