{"id":19339733,"url":"https://github.com/rubenv/pgtest","last_synced_at":"2025-04-23T02:30:54.430Z","repository":{"id":39732818,"uuid":"228421196","full_name":"rubenv/pgtest","owner":"rubenv","description":"PostgreSQL test helper for Go","archived":false,"fork":false,"pushed_at":"2024-04-04T11:47:36.000Z","size":37,"stargazers_count":56,"open_issues_count":2,"forks_count":7,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-02T06:43:12.045Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/rubenv.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}},"created_at":"2019-12-16T15:49:07.000Z","updated_at":"2025-03-15T02:57:34.000Z","dependencies_parsed_at":"2024-02-22T21:24:08.677Z","dependency_job_id":"bebb61e9-952b-4740-882b-05bef58f14cb","html_url":"https://github.com/rubenv/pgtest","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rubenv%2Fpgtest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rubenv%2Fpgtest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rubenv%2Fpgtest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rubenv%2Fpgtest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rubenv","download_url":"https://codeload.github.com/rubenv/pgtest/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250357567,"owners_count":21417308,"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","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":[],"created_at":"2024-11-10T03:23:36.634Z","updated_at":"2025-04-23T02:30:54.179Z","avatar_url":"https://github.com/rubenv.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pgtest\n\n\u003e Go library to spawn single-use PostgreSQL servers for unit testing\n\n[![Build Status](https://github.com/rubenv/pgtest/workflows/Test/badge.svg)](https://github.com/rubenv/pgtest/actions) [![GoDoc](https://godoc.org/github.com/rubenv/pgtest?status.png)](https://godoc.org/github.com/rubenv/pgtest)\n\nSpawns a PostgreSQL server with a single database configured. Ideal for unit\ntests where you want a clean instance each time. Then clean up afterwards.\n\nFeatures:\n\n* Starts a clean isolated PostgreSQL database\n* Tested on Fedora, Ubuntu and Alpine\n* Optimized for in-memory execution, to speed up unit tests\n* Less than 1 second startup / initialization time\n* Automatically drops permissions when testing as root\n\n## Usage\n\nIn your unit test:\n```go\npg, err := pgtest.Start()\ndefer pg.Stop()\n\n// Do something with pg.DB (which is a *sql.DB)\n```\n\n## License\n\nThis library is distributed under the [MIT](LICENSE) license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frubenv%2Fpgtest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frubenv%2Fpgtest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frubenv%2Fpgtest/lists"}