Bug 5882: Wrong placement of deprecated annotation
[mdsal.git] / binding / mdsal-binding-generator-impl / src / test / java / org / opendaylight / yangtools / sal / binding / generator / impl / GeneratedTypesLeafrefTest.java
index 48fce9f6a76e0d7f29b73471662e6323aa35fc2e..944e5f4c0e08fd58b0c1c59412949ab5066e4dbc 100644 (file)
@@ -10,7 +10,9 @@ package org.opendaylight.yangtools.sal.binding.generator.impl;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNotNull;
 import static org.junit.Assert.assertNotSame;
+import static org.junit.Assert.assertTrue;
 import static org.junit.Assert.fail;
+
 import com.google.common.io.ByteSource;
 import java.io.File;
 import java.io.IOException;
@@ -256,9 +258,8 @@ public class GeneratedTypesLeafrefTest {
             bindingGen.generateTypes(context);
             fail("Expected IllegalArgumentException caused by invalid leafref path");
         } catch (IllegalArgumentException e) {
-            String expected = "Failed to find leafref target node: ../id";
-            assertEquals(expected, e.getMessage());
+            String expected = "Failed to find leafref target: ../id in module foo (QNameModule{ns=urn:yang.foo, rev=2014-03-10})";
+            assertTrue(e.getMessage().startsWith(expected));
         }
     }
-
 }
\ No newline at end of file