Sha256: 13e7a9fe52858e001b7a1ba7c1c3d9e63dc378740ba6d556a9138ebb9fbc72aa
Contents?: true
Size: 775 Bytes
Versions: 51
Compression:
Stored size: 775 Bytes
Contents
module ForestLiana class PieStatGetterTest < ActiveSupport::TestCase test 'Pie stat getter with an aggregate on a boolean field' do stat = PieStatGetter.new(BooleanField, { type: "Pie", collection: "boolean_field", timezone: "+02:00", aggregate: "Count", group_by_field: "field" }) stat.perform assert stat.record.value.count == 0 end test 'Pie stat getter with an aggregate on a foreign key' do stat = PieStatGetter.new(BelongsToField, { type: "Pie", collection: "belongs_to_field", timezone: "+02:00", aggregate: "Count", group_by_field: "has_one_field_id" }) stat.perform assert stat.record.value.count == 30 end end end
Version data entries
51 entries across 51 versions & 1 rubygems