This repository has been archived on 2024-03-16. You can view files and clone it, but cannot push or open issues or pull requests.
orbit-4-1/vendor/plugins/liquid/test/assign_test.rb

11 lines
379 B
Ruby
Raw Normal View History

require File.dirname(__FILE__) + '/helper'
class IfElseTest < Test::Unit::TestCase
include Liquid
def test_with_filtered_expressions
assert_template_result('foo','{% assign foo = values|sort|last %}{{ foo }}', 'values' => %w{foo bar baz})
assert_template_result('foo','{% assign sorted = values|sort %}{{ sorted | last }}', 'values' => %w{foo bar baz})
end
end