generated from eliona-smart-building-assistant/device-app-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
inegration_test.go
43 lines (36 loc) · 1.64 KB
/
inegration_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
package main
import (
"testing"
"github.com/eliona-smart-building-assistant/app-integration-tests/app"
"github.com/eliona-smart-building-assistant/app-integration-tests/assert"
"github.com/eliona-smart-building-assistant/app-integration-tests/test"
)
func TestApp(t *testing.T) {
app.StartApp()
test.AppWorks(t)
t.Run("TestAssetTypes", assetTypes)
t.Run("TestSchema", schema)
app.StopApp()
}
func schema(t *testing.T) {
t.Parallel()
assert.SchemaExists(t, "abb_free_at_home", []string{"configuration", "asset", "datapoint", "datapoint_attribute"})
}
func assetTypes(t *testing.T) {
t.Parallel()
assert.AssetTypeExists(t, "abb_free_at_home_channel", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_device", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_dimmer_sensor", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_floor", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_heating_actuator", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_hue_actuator", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_movement_sensor", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_radiator_thermostat", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_room", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_room_temperature_controller", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_root", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_scene", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_switch_sensor", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_system", []string{})
assert.AssetTypeExists(t, "abb_free_at_home_window_sensor", []string{})
}