major refactoring of the api

This commit is contained in:
didier amyot committed 2015-03-28 20:53:28 -07:00
1 parent d4f7dc57fc
commit f0628e4682
38 files changed
+821 -367

No files matched your search

+5
View File
@@ -57,6 +57,11 @@ func TestValidate(t *testing.T) {
if err := dmd.Validate(); err.Error() != "the sum of the probability must be 1.0" {
t.Error(err)
}
dmd = &DoormanDefinition{Name: "foo", Values: []*DoormanValue{&DoormanValue{"foo", 0.2}, &DoormanValue{"bar", 0.2}}}
if err := dmd.Validate(); err.Error() != "the sum of the probability must be 1.0" {
t.Error(err)
}
}
func TestAsJson(t *testing.T) {