{"id":31823687,"url":"https://github.com/gekorob/texp","last_synced_at":"2025-10-11T14:55:20.763Z","repository":{"id":57605665,"uuid":"163673851","full_name":"gekorob/texp","owner":"gekorob","description":"Testing by Expectations simple mini-framework","archived":false,"fork":false,"pushed_at":"2019-02-27T10:32:09.000Z","size":68,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-06-20T07:59:26.946Z","etag":null,"topics":["expect","go","golang","tdd","test","testing"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gekorob.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}},"created_at":"2018-12-31T14:08:13.000Z","updated_at":"2024-06-20T07:59:26.947Z","dependencies_parsed_at":"2022-09-26T17:31:42.087Z","dependency_job_id":null,"html_url":"https://github.com/gekorob/texp","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/gekorob/texp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gekorob%2Ftexp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gekorob%2Ftexp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gekorob%2Ftexp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gekorob%2Ftexp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gekorob","download_url":"https://codeload.github.com/gekorob/texp/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gekorob%2Ftexp/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279007471,"owners_count":26084313,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-11T02:00:06.511Z","response_time":55,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["expect","go","golang","tdd","test","testing"],"created_at":"2025-10-11T14:55:10.383Z","updated_at":"2025-10-11T14:55:20.757Z","avatar_url":"https://github.com/gekorob.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TEXP\n\n[![Go Report Card](https://goreportcard.com/badge/github.com/gekorob/texp)](https://goreportcard.com/report/github.com/gekorob/texp) [![GoDoc](https://godoc.org/github.com/gekorob/texp?status.png)](http://godoc.org/github.com/gekorob/texp) [![Build Status](https://travis-ci.org/gekorob/texp.svg?branch=master)](https://travis-ci.org/gekorob/texp)\n\n## Testing by Expectations simple mini-framework\n\nEasy expectations based testing mini-framework inspired by the wonderful Mat Ryer [\"is\"](https://github.com/matryer/is) project, but for RSpec nostalgic like me.\nThis project is a working progress, so expect changes and more new things.\n\n### Basic usage\n\nUsing Texp with default settings is very simple\n\n```go\nimport (\n  ...\n  \"testing\"\n\n  \"github.com/gekorob/texp\"\n  ...\n)\n\nfunc TestSomething(t *testing.T) {\n  expect := texp.Expect(t)\n\n  expect(2 == 2).ToBeTrue()\n}\n\nfunc TestSomethingOther(t *testing.T) {\n  expect := texp.Expect(t)\n\n  expect(3).ToEqual(2)\n}\n```\n\n### Instance configuration\n\nWith Texp you can change the default configuration for each test, setting an output different from the StdOut or an alternative style (implementing the appropriate interface)\n\n```go\nimport (\n  ...\n  \"strings\"\n  \"testing\"\n\n  \"github.com/gekorob/texp\"\n  \"github.com/gekorob/texp/conf\"\n  ...\n)\n\nfunc TestSomething(t *testing.T) {\n  var b strings.Builder\n  yourStyle := ....\n\n  expect := texp.Expect(t, conf.OutputTo(\u0026b, conf.StyleWith(yourStyle))\n\n  expect(1 == 1).ToBeTrue()\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgekorob%2Ftexp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgekorob%2Ftexp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgekorob%2Ftexp/lists"}