Skip to content

Commit

Permalink
Fix PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
idastambuk committed Oct 19, 2023
1 parent dc3916f commit c388082
Show file tree
Hide file tree
Showing 3 changed files with 132 additions and 16 deletions.
4 changes: 2 additions & 2 deletions pkg/framer/property_value.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ func (p AssetPropertyValue) Frames(ctx context.Context, resources resource.Resou
if err != nil {
return nil, err
}
var property *iotsitewise.DescribeAssetPropertyOutput

for _, e := range p.SuccessEntries {
property = properties[*e.EntryId]
property := properties[*e.EntryId]
timeField := fields.TimeField(0)
valueField := fields.PropertyValueField(property, 0)
qualityField := fields.QualityField(0)
Expand Down
2 changes: 0 additions & 2 deletions pkg/server/test/property_value_aggregate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ type test struct {
name string
query string
isExpression bool
isDisassociated bool
expectedMaxPages int
expectedMaxResults int
expectedDescribeTimeSeriesWithContextArgs *iotsitewise.DescribeTimeSeriesInput
Expand Down Expand Up @@ -209,7 +208,6 @@ func TestPropertyValueAggregateWithDisassociatedStream(t *testing.T) {
expectedDescribeTimeSeriesWithContextArgs: &iotsitewise.DescribeTimeSeriesInput{Alias: Pointer("/amazon/renton/1/rpm")},
expectedMaxPages: 1,
expectedMaxResults: 0,
isDisassociated: true,
}

t.Run(tc.name, func(t *testing.T) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,23 @@
// }
// }
// Name:
// Dimensions: 3 Fields by 0 Rows
// +-------------------+----------------------------+----------------+
// | Name: time | Name: /amazon/renton/1/rpm | Name: quality |
// | Labels: | Labels: | Labels: |
// | Type: []time.Time | Type: []float64 | Type: []string |
// +-------------------+----------------------------+----------------+
// +-------------------+----------------------------+----------------+
// Dimensions: 3 Fields by 35 Rows
// +-------------------------------+----------------------------+----------------+
// | Name: time | Name: /amazon/renton/1/rpm | Name: quality |
// | Labels: | Labels: | Labels: |
// | Type: []time.Time | Type: []bool | Type: []string |
// +-------------------------------+----------------------------+----------------+
// | 2021-02-01 17:30:00 +0100 CET | true | GOOD |
// | 2021-02-01 17:35:00 +0100 CET | true | GOOD |
// | 2021-02-01 17:40:00 +0100 CET | false | GOOD |
// | 2021-02-01 17:45:00 +0100 CET | false | GOOD |
// | 2021-02-01 17:50:00 +0100 CET | true | GOOD |
// | 2021-02-01 17:55:00 +0100 CET | true | GOOD |
// | 2021-02-01 18:00:00 +0100 CET | false | GOOD |
// | 2021-02-01 18:05:00 +0100 CET | false | GOOD |
// | 2021-02-01 18:10:00 +0100 CET | true | GOOD |
// | ... | ... | ... |
// +-------------------------------+----------------------------+----------------+
//
//
// 🌟 This was machine generated. Do not edit. 🌟
Expand Down Expand Up @@ -44,9 +54,9 @@
},
{
"name": "/amazon/renton/1/rpm",
"type": "number",
"type": "boolean",
"typeInfo": {
"frame": "float64"
"frame": "bool"
},
"config": {}
},
Expand All @@ -61,9 +71,117 @@
},
"data": {
"values": [
[],
[],
[]
[
1612197000000,
1612197300000,
1612197600000,
1612197900000,
1612198200000,
1612198500000,
1612198800000,
1612199100000,
1612199400000,
1612199700000,
1612200000000,
1612200300000,
1612200600000,
1612200900000,
1612201200000,
1612201500000,
1612201800000,
1612202100000,
1612202400000,
1612202700000,
1612203000000,
1612203300000,
1612203600000,
1612203900000,
1612204200000,
1612204500000,
1612204800000,
1612205100000,
1612205400000,
1612205700000,
1612206000000,
1612206300000,
1612206600000,
1612206900000,
1612207200000
],
[
true,
true,
false,
false,
true,
true,
false,
false,
true,
true,
false,
false,
true,
true,
false,
false,
true,
true,
false,
false,
true,
true,
false,
false,
true,
true,
false,
false,
true,
true,
false,
false,
true,
true,
false
],
[
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD",
"GOOD"
]
]
}
}
Expand Down

0 comments on commit c388082

Please sign in to comment.