{"id":26154403,"url":"https://github.com/rcdmk/classicaspunit","last_synced_at":"2026-03-09T12:35:31.098Z","repository":{"id":4999757,"uuid":"6157981","full_name":"rcdmk/classicAspUnit","owner":"rcdmk","description":"A classic ASP unit framework for helping in testing classic asp code.","archived":false,"fork":false,"pushed_at":"2012-11-16T02:55:31.000Z","size":120,"stargazers_count":6,"open_issues_count":0,"forks_count":5,"subscribers_count":4,"default_branch":"master","last_synced_at":"2023-03-12T10:01:36.552Z","etag":null,"topics":["asp","classic-asp","unit-testing"],"latest_commit_sha":null,"homepage":null,"language":"ASP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"radar/forem-redcarpet","license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rcdmk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-10-10T13:45:48.000Z","updated_at":"2021-05-16T16:13:13.000Z","dependencies_parsed_at":"2022-09-15T03:12:20.340Z","dependency_job_id":null,"html_url":"https://github.com/rcdmk/classicAspUnit","commit_stats":null,"previous_names":[],"tags_count":1,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rcdmk%2FclassicAspUnit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rcdmk%2FclassicAspUnit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rcdmk%2FclassicAspUnit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rcdmk%2FclassicAspUnit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rcdmk","download_url":"https://codeload.github.com/rcdmk/classicAspUnit/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242999842,"owners_count":20219578,"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":["asp","classic-asp","unit-testing"],"created_at":"2025-03-11T08:29:30.818Z","updated_at":"2026-03-09T12:35:31.025Z","avatar_url":"https://github.com/rcdmk.png","language":"ASP","funding_links":[],"categories":[],"sub_categories":[],"readme":"Classic ASPUnit\n===============\n\nA classic ASP unit framework for helping in testing classic asp code.\n\n# Usage\n\u003c!-- languages: vbscript --\u003e\n\t\nInstantiate the context:\n\n    set testContext = new aspUnit\n\t\nCreate a test case:\n\n\tset oTest = testContext.addTestCase(\"User Administration\")\n\nMake assertions:\n\n\toTestMethod.AssertExists usersDB, \"optional message override: {1}\" ' accepts a wildcard marks for the parammeters\n\toTestMethod.AssertIsA usersDB, \"testDB\", \"\" ' leave blank for default message\n\nYou can also create test setups and teardowns to be executed before and after each test for a `Test Case`:\n\n\tsub testSetup()\n\t\tset usersDB = new testDB\n\n\t\tusersDB.TableName = \"users\"\n\t\t\n\t\tset newUser = new User\n\t\tnewUser.id = 1\n\t\tnewUser.name = \"Bob\"\n\t\t\n\t\tusersDB.add newUser\n\tend sub\n\n\tsub testTeardown()\n\t\tset usersDB = nothing\n\tend sub\n\t\n... and then pass the method names for the Test Case:\n\n\toTest.Setup(\"testSetup\")\n\toTest.Teardown(\"testTeardown\")\n\t\nThis would work too:\n\n\toTest.Setup(\"myGlobalObject.MyMethod(1, \"\"param2\"\", true)\")\n\t\n\u003e **Warning:** This uses `Execute` to run the code and will accpect any executable code string like `\"myVar = 1\"` or `\"myFunction() : myOtherFunction()\"`\n\n\nTo run and get the results of the tests:\n\n\tset results = testContext.run\n\tresults.Update ' This will update the test counters for passed, failed and errors\n\nThen you can have access to the results and write any view you want:\n\n\tResponse.Write \"Test Cases: \" \u0026 results.TestCases.Count \u0026 \"\u003cbr\u003e\"\n\tResponse.Write \"Tests runned: \" \u0026 results.Tests \u0026 \", \"\n\tResponse.Write \"Tests passed: \" \u0026 results.Passed \u0026 \", \"\n\tResponse.Write \"Tests failed: \" \u0026 results.Failed \u0026 \", \"\n\tResponse.Write \"Tests errored: \" \u0026 results.Errors \u0026 \"\u003cbr\u003e\u003cbr\u003e\"\n\n\t' loop the testCases\n\tfor each testCase in result.TestCases.Items\n\t\tResponse.Write \"-\u003e Test Case: \" \u0026 testCase.Name \u0026 \"(\" \u0026 testCase.Status \u0026 \")\u003cbr\u003e\"\n\t\t\n\t\t' loop the tests\n\t\tfor each test in testCase.Tests.Items\n\t\t\tResponse.Write \"--\u003e Test: \" \u0026 test.Name \u0026 \"\u003cbr\u003e\"\n\t\t\tResponse.Write \"----\u003e \" \u0026 test.Output \u0026 \"(\" \u0026 test.Status \u0026 \")\u003cbr\u003e\"\n\t\tnext\n\tnext\n\t\n\u003eThere is a template view with the source in the test folder.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frcdmk%2Fclassicaspunit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frcdmk%2Fclassicaspunit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frcdmk%2Fclassicaspunit/lists"}