{"id":32168302,"url":"https://github.com/siiibo/assert_match","last_synced_at":"2026-03-09T08:31:42.950Z","repository":{"id":59739470,"uuid":"536112537","full_name":"siiibo/assert_match","owner":"siiibo","description":"Leverages pattern matching \u0026 pipeline in Elixir tests!","archived":false,"fork":false,"pushed_at":"2025-01-31T06:52:51.000Z","size":64,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-10-21T15:51:30.416Z","etag":null,"topics":["elixir","testing"],"latest_commit_sha":null,"homepage":"","language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/siiibo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-09-13T12:21:01.000Z","updated_at":"2025-01-31T06:52:54.000Z","dependencies_parsed_at":"2023-12-05T11:45:45.016Z","dependency_job_id":"1aea5cba-0777-456d-864c-98b1ad6bb76a","html_url":"https://github.com/siiibo/assert_match","commit_stats":{"total_commits":27,"total_committers":3,"mean_commits":9.0,"dds":"0.18518518518518523","last_synced_commit":"caed3e59780923cdc7a4730ac1c50f0a6d19fe98"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/siiibo/assert_match","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siiibo%2Fassert_match","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siiibo%2Fassert_match/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siiibo%2Fassert_match/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siiibo%2Fassert_match/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/siiibo","download_url":"https://codeload.github.com/siiibo/assert_match/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siiibo%2Fassert_match/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30084686,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-04T13:22:36.021Z","status":"ssl_error","status_checked_at":"2026-03-04T13:20:45.750Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["elixir","testing"],"created_at":"2025-10-21T15:50:37.061Z","updated_at":"2026-03-09T08:31:42.938Z","avatar_url":"https://github.com/siiibo.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AssertMatch\n\n[![Elixir CI](https://github.com/siiibo/assert_match/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/siiibo/assert_match/actions/workflows/build.yml)\n\nLeverages pattern matching \u0026 pipeline in Elixir tests!\n\n## Motivation\n\nIn short, we wanted this:\n\n```elixir\ntest \"/some/api should work\", context do\n  conn\n  |\u003e post(\"/some/api\")\n  |\u003e json_response(200)\n  |\u003e assert_match(%{\n    \"success\" =\u003e true,\n    \"id\" =\u003e ^context.some_fixture.id,\n    \"bytesize\" =\u003e ^byte_size(context.some_fixture.contents)\n  })\nend\n```\n\n* **Write assertions in pipeline**\n* **Assert by patterns**, not just concrete values (utilizing pattern-matching diffs in Elixir 1.10+)\n* Expand **function calls inside pins**, inspired by [Ecto.Query](https://hexdocs.pm/ecto/Ecto.Query.html#module-interpolation-and-casting)\n\n### Introductory talk\n\n\u003ca href=\"https://docs.google.com/presentation/d/e/2PACX-1vRuIA2ocDafLRJUn6nWScZmOq6YwpqXba7x5RG72yzT3X7FB-JcET33QMGsBidHsAdbnVF9KYCOa00R/pub?start=false\u0026loop=false\u0026delayms=3000\u0026slide=id.p\"\u003e\u003cimg src=\"slide.png\" alt=\"Further leveraging pattern matches in Elixir unit tests!\" width=\"320\"/\u003e\u003c/a\u003e\n\n## Installation\n\n```elixir\ndef deps do\n  [\n    # If available in Hex\n    {:assert_match, \"~\u003e 1.0\", only: [:test]}\n    # If not, or, if you need bleeding edge\n    {:assert_match, github: \"siiibo/assert_match\", ref: \"main\", only: [:test]}\n  ]\nend\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsiiibo%2Fassert_match","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsiiibo%2Fassert_match","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsiiibo%2Fassert_match/lists"}