Skip to content

Commit

Permalink
Fix opcua integration test (influxdata#9107)
Browse files Browse the repository at this point in the history
  • Loading branch information
R290 authored Apr 9, 2021
1 parent 9853bf6 commit 114e4c2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
4 changes: 4 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,10 @@ services:
image: ncarlier/mqtt
ports:
- "1883:1883"
opcua:
image: open62541/open62541
ports:
- "4840:4840"
riemann:
image: stealthly/docker-riemann
ports:
Expand Down
6 changes: 4 additions & 2 deletions plugins/inputs/opcua/opcua_client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ type OPCTags struct {
}

func TestClient1Integration(t *testing.T) {
t.Skip("Skipping due to dial tcp 195.254.227.245:4840: connect: connection refused")
if testing.Short() {
t.Skip("Skipping integration test in short mode")
}

var testopctags = []OPCTags{
{"ProductName", "0", "i", "2261", "open62541 OPC UA Server"},
Expand All @@ -32,7 +34,7 @@ func TestClient1Integration(t *testing.T) {
var err error

o.MetricName = "testing"
o.Endpoint = "opc.tcp://opcua.rocks:4840"
o.Endpoint = "opc.tcp://localhost:4840"
o.AuthMethod = "Anonymous"
o.ConnectTimeout = config.Duration(10 * time.Second)
o.RequestTimeout = config.Duration(1 * time.Second)
Expand Down

0 comments on commit 114e4c2

Please sign in to comment.