{"id":13786641,"url":"https://github.com/tvastar/test","last_synced_at":"2026-01-12T10:53:14.327Z","repository":{"id":57496822,"uuid":"177343374","full_name":"tvastar/test","owner":"tvastar","description":"test utilities for golang","archived":false,"fork":false,"pushed_at":"2019-09-23T01:09:27.000Z","size":54,"stargazers_count":9,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-05-11T22:39:10.629Z","etag":null,"topics":["golang","golden","golden-file","markdown","markdown-converter","snippets","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/tvastar.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-03-23T21:47:36.000Z","updated_at":"2023-10-30T05:53:01.000Z","dependencies_parsed_at":"2022-09-03T02:30:46.057Z","dependency_job_id":null,"html_url":"https://github.com/tvastar/test","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tvastar/test","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tvastar%2Ftest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tvastar%2Ftest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tvastar%2Ftest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tvastar%2Ftest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tvastar","download_url":"https://codeload.github.com/tvastar/test/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tvastar%2Ftest/sbom","scorecard":{"id":903287,"data":{"date":"2025-05-12","repo":{"name":"github.com/tvastar/test","commit":"84aa581ec8855ae245fca2b60b791c1d39db2f5b"},"scorecard":{"version":"v5.1.1-45-g40bbc9c9","commit":"40bbc9c958aa66327fb026b2136f1951298ca0f8"},"score":2.8,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/15 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#token-permissions"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#binary-artifacts"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#dangerous-workflow"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: downloadThenRun not pinned by hash: x/upload_coverage.sh:12","Info:   0 out of   1 downloadThenRun dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#signed-releases"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 29 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/40bbc9c958aa66327fb026b2136f1951298ca0f8/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-24T16:27:16.168Z","repository_id":57496822,"created_at":"2025-08-24T16:27:16.169Z","updated_at":"2025-08-24T16:27:16.169Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28338850,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-12T10:40:25.642Z","status":"ssl_error","status_checked_at":"2026-01-12T10:39:27.820Z","response_time":98,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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":["golang","golden","golden-file","markdown","markdown-converter","snippets","testing"],"created_at":"2024-08-03T19:01:23.852Z","updated_at":"2026-01-12T10:53:14.302Z","avatar_url":"https://github.com/tvastar.png","language":"Go","funding_links":[],"categories":["Testing"],"sub_categories":["Testing Frameworks"],"readme":"# Test\n\n[![Status](https://travis-ci.com/tvastar/test.svg?branch=master)](https://travis-ci.com/tvastar/test?branch=master)\n[![GoDoc](https://godoc.org/github.com/tvastar/test?status.svg)](https://godoc.org/github.com/tvastar/test)\n[![codecov](https://codecov.io/gh/tvastar/test/branch/master/graph/badge.svg)](https://codecov.io/gh/tvastar/test)\n[![Go Report Card](https://goreportcard.com/badge/github.com/tvastar/test)](https://goreportcard.com/report/github.com/tvastar/test)\n\nTest is a simple golang test utils package.\n\n## test.Artifact\n\ntest.Artifact allows a simple way to test artifacts against recorded\ngolden files.\n\nThe golden files are stored in `testdata/` folder of the caller of the\nAPI and are expected to contain the JSON version of the value being\ntested.  The [go-cmp](https://github.com/google/go-cmp) package is\nused for better quality diffs.\n\n## test.File\n\nThis is deprecated in favor of test.Artifact.\n\n## test.Markdown\n\nMarkdown() converts a set of code snippets in markdown into test cases. For example:\n\n````\n```go\nif len(\"hello\") != 5 {\n\tfmt.Println(\"This should not happen\")\n}\n\n// Output:\n```\n````\n\nThe above snippet is converted to an `ExampleXXX()` which runs the code.\n\nSnippets can also be named, with ability to import code from elsewhere:\n\n````\n```go  TestBoo\n// import runtime\n_, fname, _, _ := runtime.Caller(1)\nif fname == \"\" {\n\tt.Error(\"Could not find caller info\")\n}\n```\n````\n\nThe name of the snippet must be TestXYZ or ExampleXYZ or just a plain\nfunction (presumably for use in other snippets).  Two sepcial cases\nare \"skip\" to indicate the fence block should not be considered\ntestable and \"global\" to indicate the fence block is a global\nvariable:\n\n````\n```go skip\n   // this has sample code that is not expected to compile\n   booya\n```\n````\n````\n```go global\nfunc stranger() string {\n\treturn \"stranger\"\n}\n```\n````\n````\n```go Example_UsingSomethingDefinedInGlobal\nfmt.Println(\"ok\", stranger())\n\n// Output: ok stranger\n```\n````\nIf the info name has a dot in it, the word before the dot is compared\nto the package name. If they don't match the fence block is\nskipped. This allows a single markdown to have multiple fence blocks\ndestined for different packages:\n\n````\n```go firstPackage.DoSomething\n...\n```\n\n```go secondPackage.\n...\n```\n````\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftvastar%2Ftest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftvastar%2Ftest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftvastar%2Ftest/lists"}