From 85440d8272449ff9dfde326a57f49bf7134ede44 Mon Sep 17 00:00:00 2001 From: JKetelaar Date: Wed, 27 Apr 2016 02:31:23 +0200 Subject: [PATCH 1/3] [TASK] Added unit test for mac address --- pom.xml | 5 +++ .../java/org/parabot/MacAddressUnitTest.java | 34 +++++++++++++++++++ 2 files changed, 39 insertions(+) create mode 100644 src/test/java/org/parabot/MacAddressUnitTest.java diff --git a/pom.xml b/pom.xml index 2fd0d1e..1bf4a9f 100644 --- a/pom.xml +++ b/pom.xml @@ -72,6 +72,11 @@ bugsnag 1.2.8 + + junit + junit + 4.11 + diff --git a/src/test/java/org/parabot/MacAddressUnitTest.java b/src/test/java/org/parabot/MacAddressUnitTest.java new file mode 100644 index 0000000..ba93ff1 --- /dev/null +++ b/src/test/java/org/parabot/MacAddressUnitTest.java @@ -0,0 +1,34 @@ +package org.parabot; + +import org.junit.Assert; +import org.junit.Test; +import org.parabot.core.network.NetworkInterface; + +import java.util.Arrays; + +/** + * @author JKetelaar + */ +public class MacAddressUnitTest { + + @Test + public void test(){ + String[] macString = new String[]{ + "19", + "5C", + "11", + "19", + "5C", + "11" + }; + NetworkInterface networkInterface = new NetworkInterface(); + + byte[] mac = new byte[6]; + for (int j = 0; j < 6; j++) { + mac[j] = Byte.parseByte(macString[j], 16); // parses a hex number + } + NetworkInterface.setMac(mac); + + Assert.assertArrayEquals(networkInterface.getHardwareAddress(), mac); + } +} From 5f83bf6e6a10133cfedd72f83949c770fd3deac8 Mon Sep 17 00:00:00 2001 From: Jeroen Ketelaar Date: Thu, 19 May 2016 12:50:02 +0200 Subject: [PATCH 2/3] [TASK] Updated version to V2.5 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 51ffee5..ef23a16 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ # Parabot -Parabot V2.4. +Parabot V2.5. #### Website From f2379a657ef96597374b21c8b67087bb77624b3d Mon Sep 17 00:00:00 2001 From: Jeroen Ketelaar Date: Fri, 20 May 2016 00:32:17 +0200 Subject: [PATCH 3/3] [BUGFIX] Temporary disabled uploading of artifacts --- .travis.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index eb316e8..4a3e47b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -20,5 +20,3 @@ env: before_install: - chmod +x ./.travis/artifact-upload.sh - -after_success: sh ./.travis/artifact-upload.sh \ No newline at end of file