summaryrefslogtreecommitdiff
path: root/spec/acceptance/max_spec.rb
blob: 3caa8131bb9e4f8036b618b8466af8238a8cf409 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#! /usr/bin/env ruby -S rspec
require 'spec_helper_acceptance'

describe 'max function' do
  describe 'success' do
    it 'maxs arrays' do
      pp = <<-EOS
      $o = max("the","public","art","galleries")
      notice(inline_template('max is <%= @o.inspect %>'))
      EOS

      apply_manifest(pp, :catch_failures => true) do |r|
        expect(r.stdout).to match(/max is "the"/)
      end
    end
  end
  describe 'failure' do
    it 'handles no arguments'
  end
end