Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yamadapc/bed
bed is a work-in-progress BDD testing framework for D
https://github.com/yamadapc/bed
Last synced: about 1 month ago
JSON representation
bed is a work-in-progress BDD testing framework for D
- Host: GitHub
- URL: https://github.com/yamadapc/bed
- Owner: yamadapc
- License: mit
- Created: 2014-07-26T10:49:17.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2020-05-06T05:45:26.000Z (over 4 years ago)
- Last Synced: 2024-12-24T11:57:42.503Z (about 1 month ago)
- Language: D
- Homepage:
- Size: 590 KB
- Stars: 3
- Watchers: 3
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
bed
===
[![Build Status](https://travis-ci.org/yamadapc/bed.svg?branch=master)](https://travis-ci.org/yamadapc/bed)
[![Gitter chat](https://badges.gitter.im/yamadapc/bed.png)](https://gitter.im/yamadapc/bed)
[![Analytics](https://ga-beacon.appspot.com/UA-54450544-1/bed/README)](https://github.com/igrigorik/ga-beacon)
- - -**bed** is a BDD testing framework for D heavily inspired by TJ Holowaychuk's
Mocha (Node.js). It's still a WIP.## Current API
**(heavily subject to changes - I'm looking at the dangling `t` param)**
```d
import bed;int add(int x, int y)
{
return x + y;
}unittest
{describe("add(x, y)", {
it("1 + 3 = 3", {
assert(add(1, 3) == 4);
})it("1 + 10 = 4", {
assert(add(1, 10) == 11);
})it("2 + 2 = 5 (meant to fail)", {
assert(add(2, 2) == 5, "what the hell happened?");
})describe("when x is a negative number", {
it("-10 + 2 = -8", {
assert(add(-10, 2) == -8);
})it("-2 - 2 = -5", {
assert(add(-2, -2) == -5, "oh my!");
});
});
});}
```## Where I am at (approximately) with the output (reporter system):
![screenshot](screen.png)
## LICENSE
This code is licensed under the MIT License. See [LICENSE](LICENSE) for more
information.