{"id":18545887,"url":"https://github.com/guillaumearm/async-describe","last_synced_at":"2025-05-15T06:34:35.547Z","repository":{"id":57185515,"uuid":"114539417","full_name":"guillaumearm/async-describe","owner":"guillaumearm","description":":rainbow: - A simple way for making async tests procedures","archived":false,"fork":false,"pushed_at":"2018-04-21T19:28:41.000Z","size":81,"stargazers_count":1,"open_issues_count":2,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-19T22:01:17.520Z","etag":null,"topics":["async","async-await","async-describe","describe","test"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/guillaumearm.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":"2017-12-17T13:42:09.000Z","updated_at":"2018-08-27T08:09:38.000Z","dependencies_parsed_at":"2022-09-14T09:01:05.067Z","dependency_job_id":null,"html_url":"https://github.com/guillaumearm/async-describe","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guillaumearm%2Fasync-describe","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guillaumearm%2Fasync-describe/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guillaumearm%2Fasync-describe/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guillaumearm%2Fasync-describe/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/guillaumearm","download_url":"https://codeload.github.com/guillaumearm/async-describe/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254288801,"owners_count":22045967,"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":["async","async-await","async-describe","describe","test"],"created_at":"2024-11-06T20:22:43.448Z","updated_at":"2025-05-15T06:34:35.509Z","avatar_url":"https://github.com/guillaumearm.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"async-describe\n==============\n\nA simple way for making async tests procedures\n\n#### Installation\n```\nnpm install --save-dev async-describe\n```\n\n#### API\n\n`async-describe` is designed for running async end to end tests\n\n##### describe(text, async fn)\n- describes block can be nested.\n\n##### test(text, async fn)\n- cannot be nested in another test block.\n- should be used inside a describe block.\n\n#### Example\n```js\nconst { describe, test } = require('async-describe');\n\nconst sleep = ms =\u003e new Promise(resolve =\u003e setTimeout(resolve, ms));\n\ndescribe('tests', async () =\u003e {\n  await describe('build client', async () =\u003e {\n    await test('test');\n  });\n  await describe('start server', async () =\u003e {\n    await test('test 1', async () =\u003e {\n    })\n    await test('test 2', async () =\u003e {\n      console.warn('console.warn');\n    })\n    await test('test 3', sleep(1)) // test() can take a promise instead of an async function\n    await sleep(100);\n  });\n  await describe('additional test I')\n  await describe('additional test II', async () =\u003e {\n    await test('test3', async () =\u003e {\n      console.log('console.log');\n    })\n  })\n  await describe('run functional tests', async () =\u003e {\n    await sleep(100);\n    await test('test4', async () =\u003e {\n      throw new Error('1')\n    })\n    await test('test4', async () =\u003e {\n      throw new Error('2')\n    })\n  });\n  await describe('more test', async () =\u003e {\n    throw new Error('Fatal')\n  })\n  await describe('more test')\n  await describe('more test')\n});\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguillaumearm%2Fasync-describe","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fguillaumearm%2Fasync-describe","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguillaumearm%2Fasync-describe/lists"}