Shopify / Shopify/liquid-spec

Generated standard filter tests ignore result type

Open
#31 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Ruby
Stars
19
Forks
8
Avg merge
6h 41m
Merged PRs (30d)
2

Description

The standard library tests in the https://github.com/Shopify/liquid repo are more precise about the result they expect, since they actually compare the ruby objects themselves for equality. Instead, the specs generated from these tests case the result to a string before comparing to the expected cast result string. The casting is done using liquid, which has ambiguities about the actual type given the result of the string cast. For example, nil, "" and [] would all produce an empty string.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating how the standard library filter tests are generated in liquid-spec and compare that path with the standard library tests in Liquid. Trace where generated specs cast results to strings; done means comparisons preserve the actual result type, including distinct cases such as nil, an empty string, and an empty array.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby
Domain
testing
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.