{"id":40586325,"url":"https://github.com/ortus-docs/testbox-docs","last_synced_at":"2026-01-21T03:05:28.240Z","repository":{"id":23904296,"uuid":"27284271","full_name":"ortus-docs/testbox-docs","owner":"ortus-docs","description":"The Official TestBox Documentation","archived":false,"fork":false,"pushed_at":"2025-04-22T13:57:56.000Z","size":15733,"stargazers_count":6,"open_issues_count":0,"forks_count":30,"subscribers_count":6,"default_branch":"v6.x","last_synced_at":"2025-04-22T14:52:55.020Z","etag":null,"topics":["hacktoberfest"],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ortus-docs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null}},"created_at":"2014-11-28T22:32:30.000Z","updated_at":"2025-04-22T13:58:00.000Z","dependencies_parsed_at":"2025-01-28T13:32:26.142Z","dependency_job_id":"108120db-0f3a-43ee-a536-e72533564820","html_url":"https://github.com/ortus-docs/testbox-docs","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/ortus-docs/testbox-docs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ortus-docs%2Ftestbox-docs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ortus-docs%2Ftestbox-docs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ortus-docs%2Ftestbox-docs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ortus-docs%2Ftestbox-docs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ortus-docs","download_url":"https://codeload.github.com/ortus-docs/testbox-docs/tar.gz/refs/heads/v6.x","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ortus-docs%2Ftestbox-docs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28624342,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-21T02:47:06.670Z","status":"ssl_error","status_checked_at":"2026-01-21T02:45:44.886Z","response_time":86,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6: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":["hacktoberfest"],"created_at":"2026-01-21T03:05:23.629Z","updated_at":"2026-01-21T03:05:28.235Z","avatar_url":"https://github.com/ortus-docs.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"---\ndescription: \u003e-\n  TestBox is a next-generation testing framework based on BDD (Behavior Driven\n  Development) and TDD (Test Driven Development), providing a clean, obvious\n  syntax for writing tests.\nicon: house-chimney-user\n---\n\n# Introduction\n\n## TestBox BDD v6.x\n\n\u003cfigure\u003e\u003cpicture\u003e\u003csource srcset=\".gitbook/assets/testbox-6-light.jpg\" media=\"(prefers-color-scheme: dark)\"\u003e\u003cimg src=\".gitbook/assets/testbox-6-dark.jpg\" alt=\"\" width=\"563\"\u003e\u003c/picture\u003e\u003cfigcaption\u003e\u003c/figcaption\u003e\u003c/figure\u003e\n\n**TestBox** is a next-generation testing framework for the [BoxLang](https://www.boxlang.io) JVM language and ColdFusion (CFML) based on [BDD](http://en.wikipedia.org/wiki/Behavior-driven\\_development) (Behavior Driven Development) for providing a clean, obvious syntax for writing tests. It contains not only a testing framework, console/web runner, assertions, and expectations library but also ships with MockBox, A mocking and stubbing companion.\u0026#x20;\n\n{% tabs %}\n{% tab title=\"BDD - BoxLang\" %}\n```java\nclass{\n\n  function run(){\n  \tdescribe( \"My calculator features\", () =\u003e {\n\t\n\t\tbeforeEach( () =\u003e {\n\t\t\tvariables.calc = new Calculator()\n\t\t} )\n\t\t\t\n\t\t// Using expectations library\n\t\tit( \"can add\", () =\u003e {\n\t\t\texpect( calc.add(1,1) ).toBe( 2 )\n\t\t} )\n\t\t\n\t\t// Using assert library\n\t\ttest( \"it can multiply\", () =\u003e {\n\t\t\tassertIsEqual( calc.multiply(2,2), 4 )\n\t\t} )\n\t} )\n  }\n\n}\n```\n{% endtab %}\n\n{% tab title=\"xUnit - BoxLang\" %}\n```groovy\n/**\n * My calculator features\n */\nclass{\n\n\tproperty calc;\n\t\n\tfunction setup(){\n\t    calc = new Calculator()\n\t}\n\t\n\t// Function name includes the word 'test'\n\t// Using expectations library\n\tfunction testAdd(){\n\t    expect( calc.add(1,1) ).toBe( 2 )\n\t}\n\t\t\n\t// Any name, but with a test annotation\n\t// Using assertions library\n\t@test\n\tfunction itCanMultiply(){\n\t    $assert.isEqual( calc.multiply(2,2), 4 )\n\t}\n}\n```\n{% endtab %}\n\n{% tab title=\"BDD - CFML\" %}\n```cfscript\ncomponent{\n\n  function run(){\n  \tdescribe( \"My calculator features\", () =\u003e {\n\t\n\t\tbeforeEach( () =\u003e {\n\t\t\tvariables.calc = new Calculator()\n\t\t} );\n\t\t\t\n\t\t// Using expectations library\n\t\tit( \"can add\", () =\u003e {\n\t\t\texpect( calc.add(1,1) ).toBe( 2 )\n\t\t} );\n\t\t\n\t\t// Using assert library\n\t\ttest( \"it can multiply\", () =\u003e {\n\t\t\t$assert.isEqual( calc.multiply(2,2), 4 )\n\t\t} );\n\t} );\n  }\n\n}\n```\n{% endtab %}\n\n{% tab title=\"xUnit - CFML\" %}\n```cfscript\n/**\n * My calculator features\n */\ncomponent{\n\t\n\tproperty calc;\n\t\n\tfunction setup(){\n\t    calc = new Calculator()\n\t}\n\t\n\t// Function name includes the word 'test'\n\t// Using expectations library\n\tfunction testAdd(){\n\t    expect( calc.add(1,1) ).toBe( 2 )\n\t}\n\t\t\n\t// Any name, but with a test annotation\n\t// Using assertions library\n\tfunction itCanMultiply() test{\n\t    $assert.isEqual( calc.multiply(2,2), 4 )\n\t}\n}\n```\n{% endtab %}\n{% endtabs %}\n\n\u003cfigure\u003e\u003cimg src=\".gitbook/assets/image (15).png\" alt=\"\"\u003e\u003cfigcaption\u003e\u003cp\u003eRunner\u003c/p\u003e\u003c/figcaption\u003e\u003c/figure\u003e\n\n### Features At A Glance\n\nHere is a simple listing of features TestBox brings to the table:\n\n* BDD style or xUnit style testing\n* Testing life-cycle methods\n* [MockBox](http://wiki.coldbox.org/wiki/MockBox.cfm) integration for mocking and stubbing\n* Mocking data library for mocking JSON/complex data and relationships\n* Ability to extend and create custom test runners and reporters\n* Extensible reporters, bundled with tons of them:\n  * JSON\n  * XML\n  * JUnit XML\n  * Text\n  * Console\n  * TAP ([Test Anything Protocol](http://testanything.org/))\n  * Simple HTML\n  * Min - Minimalistic Heaven\n  * Raw\n  * CommandBox\n* Asynchronous testing\n* Multi-suite capabilities\n* Test skipping\n* Test labels and tagging\n* Testing debug output stream\n* Code Coverage via [FusionReactor](https://fusion-reactor.com/)\n* Much more!\n\n## Versioning\n\nTestBox is maintained under the [Semantic Versioning](https://semver.org) guidelines as much as possible. Releases will be numbered in the following format:\n\n```\n\u003cmajor\u003e.\u003cminor\u003e.\u003cpatch\u003e\n```\n\nAnd constructed with the following guidelines:\n\n* bumpBreaking backward compatibility bumps the major (and resets the minor and patch)\n* New additions without breaking backward compatibility bump the minor (and resets the patch)\n* Bug fixes and misc changes bump the patch\n\n## License\n\nTestBox is open source and licensed under the [Apache 2](https://www.apache.org/licenses/LICENSE-2.0.html) License. If you use it, please try to mention it in your code or website.\n\n* Copyright by Ortus Solutions, Corp\n* TestBox is a registered trademark by Ortus Solutions, Corp\n\n{% hint style=\"info\" %}\nThe ColdBox Websites, Documentation, logo, and content have a separate license, and they are separate entities.\n{% endhint %}\n\n## Discussion \u0026 Help\n\n* Help Group: [https://community.ortussolutions.com/c/communities/testbox/11](https://community.ortussolutions.com/c/communities/testbox/11)\n* BoxTeam Slack : [https://boxteam.ortussolutions.com](https://boxteam.ortussolutions.com)\n\n## Reporting a Bug\n\nWe all make mistakes from time to time :) So why not let us know about it and help us out? We also love pull requests, so please star us and fork us: [https://github.com/Ortus-Solutions/TestBox](https://github.com/Ortus-Solutions/TestBox)\n\n* By Jira: [https://ortussolutions.atlassian.net/browse/TESTBOX](https://ortussolutions.atlassian.net/browse/TESTBOX)\n\n## Professional Open Source\n\n![Ortus Solutions, Corp](\u003c.gitbook/assets/ortussolutions\\_button (1).png\u003e)\n\nTestBox is a professional open source software backed by [Ortus Solutions, Corp](https://www.ortussolutions.com/products/testbox) offering services like:\n\n* Custom Development\n* Professional Support \u0026 Mentoring\n* Training\n* Server Tuning\n* Security Hardening\n* Code Reviews\n* [Much More](https://www.ortussolutions.com/services)\n\n## Resources\n\n* Official Site: [https://www.ortussolutions.com/products/testbox](http://www.ortussolutions.com/products/testbox)\n* Current API Docs: [https://apidocs.ortussolutions.com/testbox/current](https://apidocs.ortussolutions.com/testbox/current)\n* Help Group: [https://community.ortussolutions.com/c/communities/testbox/11](https://community.ortussolutions.com/c/communities/testbox/11)\n* Source Code: [https://github.com/Ortus-Solutions/TestBox](https://github.com/Ortus-Solutions/TestBox)\n* Bug Tracker: [https://ortussolutions.atlassian.net/browse/TESTBOX](https://ortussolutions.atlassian.net/browse/TESTBOX)\n* Twitter: [@ortussolutions](http://www.twitter.com/ortussolutions)\n* Facebook: [https://www.facebook.com/ortussolutions](https://www.facebook.com/ortussolutions)\n\n#### HONOR GOES TO GOD ABOVE ALL\n\nBecause of His grace, this project exists. If you don't like this, don't read it, it's not for you.\n\n\u003e Therefore being justified by **faith**, we have peace with God through our Lord Jesus Christ: By whom also we have access by **faith** into this **grace** wherein we stand, and rejoice in hope of the glory of God. - Romans 5:5\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fortus-docs%2Ftestbox-docs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fortus-docs%2Ftestbox-docs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fortus-docs%2Ftestbox-docs/lists"}