forest_liana 1.9.1 → 1.9.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,89 +1,149 @@
1
1
  has_one_field_1:
2
2
  id: 1
3
+ checked: true
4
+ status: 0
3
5
 
4
6
  has_one_field_2:
5
7
  id: 2
8
+ checked: true
9
+ status: 0
6
10
 
7
11
  has_one_field_3:
8
12
  id: 3
13
+ checked: true
14
+ status: 0
9
15
 
10
16
  has_one_field_4:
11
17
  id: 4
18
+ checked: true
19
+ status: 0
12
20
 
13
21
  has_one_field_5:
14
22
  id: 5
23
+ checked: true
24
+ status: 0
15
25
 
16
26
  has_one_field_6:
17
27
  id: 6
28
+ checked: true
29
+ status: 0
18
30
 
19
31
  has_one_field_7:
20
32
  id: 7
33
+ checked: true
34
+ status: 0
21
35
 
22
36
  has_one_field_8:
23
37
  id: 8
38
+ checked: true
39
+ status: 0
24
40
 
25
41
  has_one_field_9:
26
42
  id: 9
43
+ checked: true
44
+ status: 0
27
45
 
28
46
  has_one_field_10:
29
47
  id: 10
48
+ checked: true
49
+ status: 0
30
50
 
31
51
  has_one_field_11:
32
52
  id: 11
53
+ checked: true
54
+ status: 0
33
55
 
34
56
  has_one_field_12:
35
57
  id: 12
58
+ checked: true
59
+ status: 0
36
60
 
37
61
  has_one_field_13:
38
62
  id: 13
63
+ checked: true
64
+ status: 0
39
65
 
40
66
  has_one_field_14:
41
67
  id: 14
68
+ checked: true
69
+ status: 0
42
70
 
43
71
  has_one_field_15:
44
72
  id: 15
73
+ checked: true
74
+ status: 0
45
75
 
46
76
  has_one_field_16:
47
77
  id: 16
78
+ checked: true
79
+ status: 0
48
80
 
49
81
  has_one_field_17:
50
82
  id: 17
83
+ checked: true
84
+ status: 0
51
85
 
52
86
  has_one_field_18:
53
87
  id: 18
88
+ checked: true
89
+ status: 0
54
90
 
55
91
  has_one_field_19:
56
92
  id: 19
93
+ checked: true
94
+ status: 0
57
95
 
58
96
  has_one_field_20:
59
97
  id: 20
98
+ checked: true
99
+ status: 0
60
100
 
61
101
  has_one_field_21:
62
102
  id: 21
103
+ checked: true
104
+ status: 0
63
105
 
64
106
  has_one_field_22:
65
107
  id: 22
108
+ checked: true
109
+ status: 0
66
110
 
67
111
  has_one_field_23:
68
112
  id: 23
113
+ checked: true
114
+ status: 0
69
115
 
70
116
  has_one_field_24:
71
117
  id: 24
118
+ checked: true
119
+ status: 0
72
120
 
73
121
  has_one_field_25:
74
122
  id: 25
123
+ checked: true
124
+ status: 0
75
125
 
76
126
  has_one_field_26:
77
127
  id: 26
128
+ checked: true
129
+ status: 0
78
130
 
79
131
  has_one_field_27:
80
132
  id: 27
133
+ checked: true
134
+ status: 0
81
135
 
82
136
  has_one_field_28:
83
137
  id: 28
138
+ checked: true
139
+ status: 0
84
140
 
85
141
  has_one_field_29:
86
142
  id: 29
143
+ checked: true
144
+ status: 0
87
145
 
88
146
  has_one_field_30:
89
147
  id: 30
148
+ checked: true
149
+ status: 1
@@ -17,7 +17,7 @@ module ForestLiana
17
17
  assert stat.record.value[:countCurrent] == 0
18
18
  end
19
19
 
20
- test 'Value stat getter with a filter on a belongs_to field' do
20
+ test 'Value stat getter with a filter on a belongs_to integer field' do
21
21
  stat = ValueStatGetter.new(BelongsToField, {
22
22
  type: "Value",
23
23
  collection: "belongs_to_field",
@@ -33,5 +33,39 @@ module ForestLiana
33
33
  stat.perform
34
34
  assert stat.record.value[:countCurrent] == 1
35
35
  end
36
+
37
+ test 'Value stat getter with a filter on a belongs_to boolean field' do
38
+ stat = ValueStatGetter.new(BelongsToField, {
39
+ type: "Value",
40
+ collection: "belongs_to_field",
41
+ timezone: "+02:00",
42
+ aggregate: "Count",
43
+ filterType: "and",
44
+ filters: [{
45
+ field: "has_one_field:checked",
46
+ value: "false"
47
+ }]
48
+ })
49
+
50
+ stat.perform
51
+ assert stat.record.value[:countCurrent] == 0
52
+ end
53
+
54
+ test 'Value stat getter with a filter on a belongs_to enum field' do
55
+ stat = ValueStatGetter.new(BelongsToField, {
56
+ type: "Value",
57
+ collection: "belongs_to_field",
58
+ timezone: "+02:00",
59
+ aggregate: "Count",
60
+ filterType: "and",
61
+ filters: [{
62
+ field: "has_one_field:status",
63
+ value: "pending"
64
+ }]
65
+ })
66
+
67
+ stat.perform
68
+ assert stat.record.value[:countCurrent] == 1
69
+ end
36
70
  end
37
71
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: forest_liana
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.1
4
+ version: 1.9.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sandro Munda
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-10-04 00:00:00.000000000 Z
11
+ date: 2017-10-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails