@Override
    public Set<Link> getDeviceLinks(DeviceId deviceId) {
        checkNotNull(deviceId, DEVICE_NULL);
        return manager.getVirtualLinks(this.networkId())
                .stream()
                .filter(link -> (deviceId.equals(link.src().elementId()) ||
                        deviceId.equals(link.dst().elementId())))
                .collect(Collectors.toSet());
    }
@Test(expected = NullPointerException.class)
    public void testGetDeviceLinksByNullId() {
        manager.registerTenantId(TenantId.tenantId(tenantIdValue1));
        VirtualNetwork virtualNetwork = manager.createVirtualNetwork(TenantId.tenantId(tenantIdValue1));
        LinkService linkService = manager.get(virtualNetwork.id(), LinkService.class);

        // test the getDeviceLinks() method with a null device identifier.
        linkService.getDeviceLinks(null);
    }