@@ -9,7 +9,27 @@ import (
9
9
"github.com/stretchr/testify/assert"
10
10
)
11
11
12
- func TestGenerateAndGenerateZeroCapacity (t * testing.T ) {
12
+ func TestGenerateAndGenerateZeroCapacity_v16 (t * testing.T ) {
13
+ baseCfg_expected := readFile ("testdata/base-16-cfg.xml" )
14
+ adminCfg_expected := readFile ("testdata/admin-16-cfg.xml" )
15
+ zeroCfg_expected := readFile ("testdata/zero-16-cfg.xml" )
16
+
17
+ ispn := Infinispan {Authorization : & Authorization {Enabled : true }}
18
+ spec := Spec {Infinispan : ispn }
19
+ vers := semver.Version {Major : 16 , Minor : 0 , Patch : 0 }
20
+ ope := version.Operand {UpstreamVersion : & vers }
21
+
22
+ baseCfg , adminCfg , err := Generate (ope , & spec )
23
+ assert .Equal (t , baseCfg_expected , baseCfg )
24
+ assert .Equal (t , adminCfg_expected , adminCfg )
25
+ assert .Nil (t , err )
26
+
27
+ zeroCfg , err := GenerateZeroCapacity (ope , & spec )
28
+ assert .Equal (t , zeroCfg_expected , zeroCfg )
29
+ assert .Nil (t , err )
30
+ }
31
+
32
+ func TestGenerateAndGenerateZeroCapacity_v15 (t * testing.T ) {
13
33
baseCfg_expected := readFile ("testdata/base-15-cfg.xml" )
14
34
adminCfg_expected := readFile ("testdata/admin-15-cfg.xml" )
15
35
zeroCfg_expected := readFile ("testdata/zero-15-cfg.xml" )
0 commit comments