2 * Copyright (c) 2015 CableLabs and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
9 package org.opendaylight.controller.packetcable.provider.validation.impl;
11 import static junit.framework.TestCase.assertNotNull;
12 import static org.hamcrest.CoreMatchers.instanceOf;
13 import static org.hamcrest.MatcherAssert.assertThat;
15 import org.junit.Test;
16 import org.opendaylight.controller.packetcable.provider.validation.ValidatorProvider;
17 import org.opendaylight.yang.gen.v1.urn.packetcable.rev161107.Ccaps;
18 import org.opendaylight.yang.gen.v1.urn.packetcable.rev161107.ccap.attributes.AmId;
19 import org.opendaylight.yang.gen.v1.urn.packetcable.rev161107.ccap.attributes.Connection;
20 import org.opendaylight.yang.gen.v1.urn.packetcable.rev161107.ccaps.Ccap;
25 public class CcapsValidatorProviderFactoryTest {
27 private final CcapsValidatorProviderFactory factory = new CcapsValidatorProviderFactory();
30 public void validBuild() {
31 assertNotNull(factory.build());
32 assertThat(factory.build(), instanceOf(ValidatorProvider.class));
34 assertNotNull(factory.build().validatorFor(Ccaps.class));
35 assertNotNull(factory.build().validatorFor(Ccap.class));
36 assertNotNull(factory.build().validatorFor(AmId.class));
37 assertNotNull(factory.build().validatorFor(Connection.class));