Skip to content
Snippets Groups Projects
Select Git revision
  • 685431c9849f43d2c4fbf2521550d01f26d7bd0b
  • master default protected
  • L2SS-2199-apply-dab-to-xy
  • L2SS-2417-more-vector-memory
  • test-pytango-10.0.3
  • revert-cs032-ccd-ip
  • deploy-components-parallel
  • fix-chrony-exporter
  • L2SS-2407-swap-iers-caltable-monitoring-port
  • L2SS-2357-fix-ruff
  • sync-up-with-meta-pypcc
  • stabilise-landing-page
  • all-stations-lofar2
  • v0.39.7-backports
  • Move-sdptr-to-v1.5.0
  • fix-build-ubuntu
  • tokens-in-env-files
  • fix-build
  • L2SS-2214-deploy-cdb
  • fix-missing-init
  • add-power-hardware-apply
  • v0.55.5-r2 protected
  • v0.52.8-rc1 protected
  • v0.55.5 protected
  • v0.55.4 protected
  • 0.55.2.dev0
  • 0.55.1.dev0
  • 0.55.0.dev0
  • v0.54.0 protected
  • 0.53.2.dev0
  • 0.53.1.dev0
  • v0.52.3-r2 protected
  • remove-snmp-client
  • v0.52.3 protected
  • v0.52.3dev0 protected
  • 0.53.1dev0
  • v0.52.2-rc3 protected
  • v0.52.2-rc2 protected
  • v0.52.2-rc1 protected
  • v0.52.1.1 protected
  • v0.52.1 protected
41 results

test_unb2_sim.py

Blame
  • Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    test_unb2_sim.py 721 B
    # -*- coding: utf-8 -*-
    #
    # This file is part of the LOFAR 2.0 Station Software
    #
    #
    #
    # Distributed under the terms of the APACHE license.
    # See LICENSE.txt for more info.
    
    from asyncua import Client
    
    from integration_test import base
    
    
    class TestUNB2Sim(base.IntegrationAsyncTestCase):
    
        def setUp(self):
            super(TestUNB2Sim, self).setUp()
    
        async def test_opcua_connection(self):
            """Check if we can connect to unb2-sim"""
    
            client = Client("opc.tcp://unb2-sim:4844")
            root_node = None
    
            await client.connect()
    
            try:
                root_node = await client.get_root_node()
            finally:
                await client.disconnect()
    
            self.assertNotEqual(None, root_node)