1
0
mirror of https://github.com/MontFerret/ferret.git synced 2025-11-27 22:08:15 +02:00

Move value specific Iterable and Iterator interfaces into core module (#233)

* Move value specific Iterable and Iterator interfaces into core module

* Update Makefile

Reverted test command

* Update collection.go

* Fixed wrong iterator usage

* Updated use of switch statements
This commit is contained in:
Tim Voronov
2019-02-15 07:41:08 -05:00
committed by GitHub
parent 1af8b37a0f
commit f8e061cc80
13 changed files with 82 additions and 93 deletions

View File

@@ -23,7 +23,7 @@ func TestAppend(t *testing.T) {
So(err, ShouldBeNil)
So(out, ShouldNotEqual, arr)
So(out.(collections.Collection).Length(), ShouldBeGreaterThan, arr.Length())
So(out.(collections.Measurable).Length(), ShouldBeGreaterThan, arr.Length())
})
Convey("Should ignore non-unique items", t, func() {
@@ -39,12 +39,12 @@ func TestAppend(t *testing.T) {
So(err, ShouldBeNil)
So(out, ShouldNotEqual, arr)
So(out.(collections.Collection).Length(), ShouldEqual, arr.Length())
So(out.(collections.Measurable).Length(), ShouldEqual, arr.Length())
out2, err := arrays.Append(context.Background(), arr, values.NewInt(6), values.True)
So(err, ShouldBeNil)
So(out2, ShouldNotEqual, arr)
So(out2.(collections.Collection).Length(), ShouldBeGreaterThan, arr.Length())
So(out2.(collections.Measurable).Length(), ShouldBeGreaterThan, arr.Length())
})
}