From edd65c3f14cdf01963ff04f08ad9ca1282690302 Mon Sep 17 00:00:00 2001 From: Todd Eichel Date: Fri, 27 May 2016 14:59:39 -0700 Subject: [PATCH] Allow passing custom environments when making Liquid contexts for testing. Backwards-compatible with previous implementation. --- spec/spec_helper.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 4bf3092..a83c8fd 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -38,6 +38,6 @@ def make_site(options = {}) Jekyll::Site.new(config) end -def make_context(registers = {}) - Liquid::Context.new({}, {}, { site: site, page: page }.merge(registers)) +def make_context(registers = {}, environments: {}) + Liquid::Context.new(environments, {}, { site: site, page: page }.merge(registers)) end