hunk.code_window:   t.equal(typeof inflight, 'function', 'dev dependency is available')
     await project.hasNot('once')
     const shr = await project.loadShrinkwrap()
  
hunk.labels: keep keep keep keep replace keep
hunk.after_edit:   {
       const shr = await project.loadShrinkwrap()
       t.ok(shr.packages['/is-positive/1.0.0'].dev === false)
     }
     {
       const currentShrinkwrap = await project.loadCurrentShrinkwrap()
       t.notOk(currentShrinkwrap.packages['/is-positive/1.0.0'], 'prod dep only not added to current shrinkwrap.yaml')
     }
  
hunk.file_path: test/install/only.ts
hunk.type: replace
file: import {stripIndent, oneLine} from 'common-tags'
  import {Modules, LAYOUT_VERSION} from '../fs/modulesController'
  import {PnpmError, PnpmErrorCode} from '../errorTypes'
  import semver = require('semver')
  
  class UnexpectedStoreError extends PnpmError {
    constructor (
      opts: {
        expectedStorePath: string,
        actualStorePath: string,
      }
    ) {
      super('UNEXPECTED_STORE', 'Unexpected store used for installation')
      this.expectedStorePath = opts.expectedStorePath
      this.actualStorePath = opts.actualStorePath
    }
    expectedStorePath: string
    actualStorePath: string
  }
  
  type BreakingChangeErrorOptions = ErrorRelatedSources & {
    code: PnpmErrorCode,
    message: string,
  }
  
  type ErrorRelatedSources = {
    additionalInformation?: string,
    relatedIssue?: number,
    relatedPR?: number,
  }
  
  class BreakingChangeError extends PnpmError {
    constructor (opts: BreakingChangeErrorOptions) {
      super(opts.code, opts.message)
      this.relatedIssue = opts.relatedIssue
      this.relatedPR = opts.relatedPR
      this.additionalInformation = opts.additionalInformation
    }
    relatedIssue?: number
    relatedPR?: number
    additionalInformation?: string
  }
  
  type ModulesBreakingChangeErrorOptions = ErrorRelatedSources & {
    modulesPath: string,
  }
  
  class ModulesBreakingChangeError extends BreakingChangeError {
    constructor (opts: ModulesBreakingChangeErrorOptions) {
      super({
        code: 'MODULES_BREAKING_CHANGE',
        message: `The node_modules structure at ${opts.modulesPath} was changed. Try running the same command with the --force parameter.`,
        additionalInformation: opts.additionalInformation,
        relatedIssue: opts.relatedIssue,
        relatedPR: opts.relatedPR,
      })
      this.modulesPath = opts.modulesPath
    }
    modulesPath: string
  }
  
  export default function checkCompatibility (
    modules: Modules,
    opts: {
      storePath: string,
      modulesPath: string,
    }
  ) {
    if (modules.store !== opts.storePath) {
      throw new UnexpectedStoreError({
        expectedStorePath: modules.store,
        actualStorePath: opts.storePath,
      })
    }
    if (!modules.layoutVersion || modules.layoutVersion !== LAYOUT_VERSION) {
      throw new ModulesBreakingChangeError({
        modulesPath: opts.modulesPath,
        additionalInformation: 'The change was needed to make `independent-leafs` not the default installation layout',
        relatedIssue: 821,
      })
    }
  }
  