bed 0.0.2
Small BDD testing framework for D.
To use this package, run the following command in your project's root directory:
Manual usage
Put the following dependency into your project's dependences section:
bed
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)
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):
LICENSE
This code is licensed under the MIT License. See LICENSE for more information.
- Registered by Pedro Tacla Yamada
- 0.0.2 released 10 years ago
- yamadapc/bed
- MIT
- Copyright © 2014, Pedro Tacla Yamada
- Authors:
- Dependencies:
- colorize
- Versions:
-
0.0.5 2014-Aug-01 0.0.4 2014-Jul-31 0.0.3 2014-Jul-31 0.0.2 2014-Jul-31 0.0.1 2014-Jul-31 - Download Stats:
-
-
0 downloads today
-
0 downloads this week
-
0 downloads this month
-
3206 downloads total
-
- Score:
- 0.3
- Short URL:
- bed.dub.pm