Testing Template Factory Instance Creation in Liquid
This test suite validates the core functionality of Liquid’s template factory implementation, focusing on proper template instance creation and type verification. The tests ensure the template factory correctly instantiates Liquid templates with expected behavior.
Test Coverage Overview
Implementation Analysis
Technical Details
Best Practices Demonstrated
shopify/liquid
test/unit/template_factory_unit_test.rb
# frozen_string_literal: true
require 'test_helper'
class TemplateFactoryUnitTest < Minitest::Test
include Liquid
def test_for_returns_liquid_template_instance
template = TemplateFactory.new.for("anything")
assert_instance_of(Liquid::Template, template)
end
end