Add request validation against xsd

Change-Id: Iadf618e50d01dd92bf9eed5b8ed98138b56c20c9
This commit is contained in:
Dominik Adam Przybysz 2015-10-24 13:46:52 +02:00
parent aabc9d75f2
commit 9a14f9bfab
10 changed files with 205 additions and 10 deletions

View file

@ -0,0 +1,9 @@
package pl.touk.mockserver.client
import groovy.transform.CompileStatic
import groovy.transform.TypeChecked
@CompileStatic
@TypeChecked
class InvalidMockRequestSchema extends RuntimeException {
}

View file

@ -42,6 +42,9 @@ class Util {
if (message == 'mock not registered') {
throw new MockDoesNotExist()
}
if (message == 'mock request schema is invalid schema') {
throw new InvalidMockRequestSchema()
}
throw new InvalidMockDefinition(message)
}