Software /
code /
prosody
Comparison
spec/util_iterators_spec.lua @ 8802:befffddf1b25
Fix wrong tests committed with 7b621a4a2e8d
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Fri, 18 May 2018 15:20:32 +0100 |
child | 8805:82d68951ec2a |
comparison
equal
deleted
inserted
replaced
8801:a6a587df3b0e | 8802:befffddf1b25 |
---|---|
1 local iter = require "util.iterators"; | |
2 local set = require "util.set"; | |
3 | |
4 describe("util.iterators", function () | |
5 describe("join", function () | |
6 it("should produce a joined iterator", function () | |
7 local expect = { "a", "b", "c", 1, 2, 3 }; | |
8 local output = {}; | |
9 for x in iter.join(iter.values({"a", "b", "c"})):append(iter.values({1, 2, 3})) do | |
10 table.insert(output, x); | |
11 end | |
12 assert.same(output, expect); | |
13 end); | |
14 end); | |
15 end); |