Sha256: c35c693d83a4ce660291ef15409ada27e5c3d313ee63e6ae5420093bc15488e9

Contents?: true

Size: 707 Bytes

Versions: 14

Compression:

Stored size: 707 Bytes

Contents

describe 'GH-1022', site: true, stdio: true do
  before do
    File.write('content/ubuntu-16.10-server-amd64.iso.txt', 'torrent contents')
    File.write('content/ubuntu-16.10-server-amd64.iso.yaml', 'distro: Ubuntu')

    File.write('layouts/default.erb', '<%= @item[:distro] %> / <%= yield %>')

    File.write('Rules', <<EOS)
  compile '/**/*' do
    layout '/default.*'
    write item.identifier
  end

  layout '/*.erb', :erb
EOS
  end

  it 'recompiles all reps of a changed item' do
    Nanoc::CLI.run(%w(compile))

    expect(File.file?('output/ubuntu-16.10-server-amd64.iso.txt')).to be
    expect(File.read('output/ubuntu-16.10-server-amd64.iso.txt')).to eq('Ubuntu / torrent contents')
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
nanoc-4.7.5 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.7.4 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.7.3 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.7.2 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.7.1 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.7.0 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.6.4 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.6.3 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.6.2 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.6.1 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.6.0 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.5.4 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.5.3 spec/nanoc/regressions/gh_1022_spec.rb
nanoc-4.5.2 spec/nanoc/regressions/gh_1022_spec.rb