Conditions | 1 |
Paths | 1 |
Total Lines | 12 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
23 | public function testUnion() { |
||
24 | $sets = []; |
||
25 | $sets[] = $this->set->makeSet('hello'); |
||
26 | $sets[] = $this->set->makeSet('goodbye'); |
||
27 | $sets[] = $this->set->makeSet([true, 3.14]); |
||
28 | |||
29 | $this->set->union($sets[0], $sets[1]); |
||
30 | $this->set->union($sets[0], $sets[0]); |
||
31 | $this->assertEquals($sets[1], $this->set->find($sets[0])); |
||
32 | $this->set->union($sets[0], $sets[2]); |
||
33 | $this->assertEquals($sets[1], $this->set->find($sets[2])); |
||
34 | } |
||
35 | } |