// Path: src/main/java/ninja/eivind/hotsreplayuploader/providers/hotslogs/HotSLogsHero.java
// @JsonIgnoreProperties(ignoreUnknown = true)
// public class HotSLogsHero implements Hero {
// 
//     @JsonProperty("PrimaryName")
//     private String primaryName;
//     @JsonProperty("ImageURL")
//     private String imageURL;
// 
//     public HotSLogsHero() {
//     }
// 
//     public HotSLogsHero(final String primaryName, final String imageURL) {
//         this.primaryName = primaryName;
//         this.imageURL = imageURL;
//     }
// 
//     @Override
//     public String toString() {
//         return primaryName;
//     }
// 
//     @Override
//     public boolean equals(final Object o) {
//         if (this == o) return true;
//         if (o == null || getClass() != o.getClass()) return false;
// 
//         final HotSLogsHero hero = (HotSLogsHero) o;
// 
//         return !(primaryName != null ? !primaryName.equals(hero.primaryName) : hero.primaryName != null)
//                 && !(imageURL != null ? !imageURL.equals(hero.imageURL) : hero.imageURL != null);
// 
//     }
// 
//     @Override
//     public int hashCode() {
//         int result = primaryName != null ? primaryName.hashCode() : 0;
//         result = 31 * result + (imageURL != null ? imageURL.hashCode() : 0);
//         return result;
//     }
// 
//     @Override
//     public String getPrimaryName() {
//         return primaryName;
//     }
// 
//     @Override
//     public void setPrimaryName(final String primaryName) {
//         this.primaryName = primaryName;
//     }
// 
//     @Override
//     public String getImageURL() {
//         return imageURL;
//     }
// 
//     @Override
//     public void setImageURL(final String imageURL) {
//         this.imageURL = imageURL;
//     }
// 
// }
// 
// Path: src/test/java/ninja/eivind/testutils/DataObjectTester.java
// public class DataObjectTester<T> {
// 
//     private Class<T> clazz;
//     private T object;
// 
//     public DataObjectTester(Class<T> clazz, T object) {
//         this.clazz = clazz;
//         this.object = object;
//     }
// 
//     public void testAllFieldsArePrivate() {
//         final Field[] fields = clazz.getDeclaredFields();
// 
//         for (final Field field : fields) {
//             assertFalse("Field is not accessible", field.isAccessible());
//         }
//     }
// 
//     public void testAllFieldsHaveProperGetters() throws Exception {
//         final Field[] fields = clazz.getDeclaredFields();
// 
//         for (final Field field : fields) {
//             final String fieldName = field.getName();
//             char[] fieldNameChars = fieldName.toCharArray();
//             fieldNameChars[0] = Character.toUpperCase(fieldNameChars[0]);
//             String upperCasedFieldName = new String(fieldNameChars);
// 
//             Method method = clazz.getMethod("get" + upperCasedFieldName);
//             boolean getterIsAccessible = method.getModifiers() == Modifier.PUBLIC;
//             if (getterIsAccessible) {
//                 field.setAccessible(true);
//                 Object invoke = method.invoke(object);
//                 assertEquals("Getter returns an equal object to the field object", field.get(object), invoke);
//             }
//         }
//     }
// 
//     public void run() throws Exception {
//         testAllFieldsArePrivate();
//         testAllFieldsHaveProperGetters();
//     }
// }


import ninja.eivind.hotsreplayuploader.providers.hotslogs.HotSLogsHero;
import ninja.eivind.testutils.DataObjectTester;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.*;
// Copyright 2015 Eivind Vegsundvåg
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package ninja.eivind.hotsreplayuploader.models;



public class HotSLogsHeroTest {
    private static final String ARFAS_NAME = "Arfas", ARFAS_URL = "Frostmourn hungers... BLAH";
    // We need some mock heroes to test on. Arfas and Ufer, I choose you!
// Path: src/main/java/ninja/eivind/hotsreplayuploader/providers/hotslogs/HotSLogsHero.java
// @JsonIgnoreProperties(ignoreUnknown = true)
// public class HotSLogsHero implements Hero {
// 
//     @JsonProperty("PrimaryName")
//     private String primaryName;
//     @JsonProperty("ImageURL")
//     private String imageURL;
// 
//     public HotSLogsHero() {
//     }
// 
//     public HotSLogsHero(final String primaryName, final String imageURL) {
//         this.primaryName = primaryName;
//         this.imageURL = imageURL;
//     }
// 
//     @Override
//     public String toString() {
//         return primaryName;
//     }
// 
//     @Override
//     public boolean equals(final Object o) {
//         if (this == o) return true;
//         if (o == null || getClass() != o.getClass()) return false;
// 
//         final HotSLogsHero hero = (HotSLogsHero) o;
// 
//         return !(primaryName != null ? !primaryName.equals(hero.primaryName) : hero.primaryName != null)
//                 && !(imageURL != null ? !imageURL.equals(hero.imageURL) : hero.imageURL != null);
// 
//     }
// 
//     @Override
//     public int hashCode() {
//         int result = primaryName != null ? primaryName.hashCode() : 0;
//         result = 31 * result + (imageURL != null ? imageURL.hashCode() : 0);
//         return result;
//     }
// 
//     @Override
//     public String getPrimaryName() {
//         return primaryName;
//     }
// 
//     @Override
//     public void setPrimaryName(final String primaryName) {
//         this.primaryName = primaryName;
//     }
// 
//     @Override
//     public String getImageURL() {
//         return imageURL;
//     }
// 
//     @Override
//     public void setImageURL(final String imageURL) {
//         this.imageURL = imageURL;
//     }
// 
// }
// 
// Path: src/test/java/ninja/eivind/testutils/DataObjectTester.java
// public class DataObjectTester<T> {
// 
//     private Class<T> clazz;
//     private T object;
// 
//     public DataObjectTester(Class<T> clazz, T object) {
//         this.clazz = clazz;
//         this.object = object;
//     }
// 
//     public void testAllFieldsArePrivate() {
//         final Field[] fields = clazz.getDeclaredFields();
// 
//         for (final Field field : fields) {
//             assertFalse("Field is not accessible", field.isAccessible());
//         }
//     }
// 
//     public void testAllFieldsHaveProperGetters() throws Exception {
//         final Field[] fields = clazz.getDeclaredFields();
// 
//         for (final Field field : fields) {
//             final String fieldName = field.getName();
//             char[] fieldNameChars = fieldName.toCharArray();
//             fieldNameChars[0] = Character.toUpperCase(fieldNameChars[0]);
//             String upperCasedFieldName = new String(fieldNameChars);
// 
//             Method method = clazz.getMethod("get" + upperCasedFieldName);
//             boolean getterIsAccessible = method.getModifiers() == Modifier.PUBLIC;
//             if (getterIsAccessible) {
//                 field.setAccessible(true);
//                 Object invoke = method.invoke(object);
//                 assertEquals("Getter returns an equal object to the field object", field.get(object), invoke);
//             }
//         }
//     }
// 
//     public void run() throws Exception {
//         testAllFieldsArePrivate();
//         testAllFieldsHaveProperGetters();
//     }
// }


// Path: src/test/java/ninja/eivind/hotsreplayuploader/models/HotSLogsHeroTest.java
import ninja.eivind.hotsreplayuploader.providers.hotslogs.HotSLogsHero;
import ninja.eivind.testutils.DataObjectTester;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.*;

// Copyright 2015 Eivind Vegsundvåg
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package ninja.eivind.hotsreplayuploader.models;



public class HotSLogsHeroTest {
    private static final String ARFAS_NAME = "Arfas", ARFAS_URL = "Frostmourn hungers... BLAH";
    // We need some mock heroes to test on. Arfas and Ufer, I choose you!
    private HotSLogsHero arfas, ufer;