Commit b9f42901 authored by Eric Bruneton's avatar Eric Bruneton

Move the test resources to the test/resources directory.

parent 5d6c7c76
Pipeline #4382 passed with stage
in 11 minutes
...@@ -25,16 +25,14 @@ ...@@ -25,16 +25,14 @@
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
// THE POSSIBILITY OF SUCH DAMAGE. // THE POSSIBILITY OF SUCH DAMAGE.
package org.objectweb.asm.commons;
import java.io.Serializable; import java.io.Serializable;
/** /**
* Test case for SerialVersionUidAddTest. * Test case for SerialVersionUIDAdder.
* *
* @author Eric Bruneton * @author Eric Bruneton
*/ */
class SerialVersionAnonymousInnerClass implements Serializable { // NOPMD(MissingSerialVersionUID) class SerialVersionAnonymousInnerClass implements Serializable {
// No serial version UID on purpose, to test SerialVersionUIDAdder. // No serial version UID on purpose, to test SerialVersionUIDAdder.
......
...@@ -25,16 +25,14 @@ ...@@ -25,16 +25,14 @@
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
// THE POSSIBILITY OF SUCH DAMAGE. // THE POSSIBILITY OF SUCH DAMAGE.
package org.objectweb.asm.commons;
import java.io.Serializable; import java.io.Serializable;
/** /**
* Test case for SerialVersionUidAddTest. * Test case for SerialVersionUIDAdder.
* *
* @author Eric Bruneton * @author Eric Bruneton
*/ */
class SerialVersionClass implements Serializable { // NOPMD(MissingSerialVersionUID) class SerialVersionClass implements Serializable {
// No serial version UID on purpose, to test SerialVersionUIDAdder. // No serial version UID on purpose, to test SerialVersionUIDAdder.
......
...@@ -25,12 +25,10 @@ ...@@ -25,12 +25,10 @@
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
// THE POSSIBILITY OF SUCH DAMAGE. // THE POSSIBILITY OF SUCH DAMAGE.
package org.objectweb.asm.commons;
import java.io.Serializable; import java.io.Serializable;
/** /**
* Test case for SerialVersionUidAddTest. * Test case for SerialVersionUIDAdder.
* *
* @author Eric Bruneton * @author Eric Bruneton
*/ */
......
...@@ -25,10 +25,8 @@ ...@@ -25,10 +25,8 @@
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
// THE POSSIBILITY OF SUCH DAMAGE. // THE POSSIBILITY OF SUCH DAMAGE.
package org.objectweb.asm.commons;
/** /**
* Test case for SerialVersionUidAddTest. * Test case for SerialVersionUIDAdder.
* *
* @author Eric Bruneton * @author Eric Bruneton
*/ */
......
...@@ -25,12 +25,10 @@ ...@@ -25,12 +25,10 @@
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
// THE POSSIBILITY OF SUCH DAMAGE. // THE POSSIBILITY OF SUCH DAMAGE.
package org.objectweb.asm.commons;
import java.io.Serializable; import java.io.Serializable;
/** /**
* Test case for SerialVersionUidAddTest. * Test case for SerialVersionUIDAdder.
* *
* @author Eric Bruneton * @author Eric Bruneton
*/ */
......
...@@ -71,32 +71,31 @@ public class SerialVersionUidAdderTest extends AsmTest { ...@@ -71,32 +71,31 @@ public class SerialVersionUidAdderTest extends AsmTest {
@Test @Test
public void testClass() throws IOException { public void testClass() throws IOException {
long actualSvuid = computeSerialVersionUid(SerialVersionClass.class.getName()); long actualSvuid = computeSerialVersionUid("SerialVersionClass");
assertEquals(1084684350676694225L, actualSvuid); assertEquals(4654798559887898126L, actualSvuid);
} }
@Test @Test
public void testAnonymousInnerClass() throws IOException { public void testAnonymousInnerClass() throws IOException {
long actualSvuid = long actualSvuid = computeSerialVersionUid("SerialVersionAnonymousInnerClass$1");
computeSerialVersionUid(SerialVersionAnonymousInnerClass.class.getName() + "$1"); assertEquals(2591057588230880800L, actualSvuid);
assertEquals(-1842070664294792585L, actualSvuid);
} }
@Test @Test
public void testInterface() throws IOException { public void testInterface() throws IOException {
long actualSvuid = computeSerialVersionUid(SerialVersionInterface.class.getName()); long actualSvuid = computeSerialVersionUid("SerialVersionInterface");
assertEquals(-3857402532274192875L, actualSvuid); assertEquals(682190902657822970L, actualSvuid);
} }
@Test @Test
public void testEmptyInterface() throws IOException { public void testEmptyInterface() throws IOException {
long actualSvuid = computeSerialVersionUid(SerialVersionEmptyInterface.class.getName()); long actualSvuid = computeSerialVersionUid("SerialVersionEmptyInterface");
assertEquals(8675733916152748550L, actualSvuid); assertEquals(-2126445979242430981L, actualSvuid);
} }
@Test @Test
public void testEnum() throws IOException { public void testEnum() throws IOException {
long actualSvuid = computeSerialVersionUid(SerialVersionEnum.class.getName()); long actualSvuid = computeSerialVersionUid("SerialVersionEnum");
assertEquals(0L, actualSvuid); assertEquals(0L, actualSvuid);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment