deprecations fixed

This commit is contained in:
Sergey Solovyev 2013-06-26 12:25:54 +04:00
parent 99e7471ebd
commit 6aa5802dea
7 changed files with 18 additions and 19 deletions

View File

@ -22,8 +22,7 @@
package org.solovyev.android;
import junit.framework.Assert;
import org.junit.Assert;
import org.junit.Test;
import org.solovyev.android.calculator.units.CalculatorNumeralBase;
import org.solovyev.common.units.Unit;
@ -34,6 +33,8 @@ import javax.annotation.Nonnull;
import java.util.Date;
import java.util.Random;
import static org.junit.Assert.assertTrue;
/**
* User: serso
* Date: 4/21/12
@ -42,11 +43,11 @@ import java.util.Random;
public class AndroidNumeralBaseTest {
@Nonnull
private final UnitConverter c = CalculatorNumeralBase.getConverter();
private final UnitConverter<String> c = CalculatorNumeralBase.getConverter();
@Test
public void testIsSupported() throws Exception {
Assert.assertTrue(c.isSupported(CalculatorNumeralBase.bin, CalculatorNumeralBase.dec));
assertTrue(c.isSupported(CalculatorNumeralBase.bin, CalculatorNumeralBase.dec));
}
@Test

View File

@ -22,8 +22,7 @@
package org.solovyev.android.calculator.history;
import junit.framework.Assert;
import org.junit.Assert;
import org.junit.Test;
import org.solovyev.android.calculator.CalculatorDisplayViewState;
import org.solovyev.android.calculator.CalculatorDisplayViewStateImpl;
@ -39,6 +38,8 @@ import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import static org.junit.Assert.assertEquals;
/**
* User: serso
* Date: 12/17/11
@ -149,12 +150,12 @@ public class HistoryUtilsTest {
state.setTime(date.getTime());
history.addState(state);
Assert.assertEquals(emptyHistory, HistoryUtils.toXml(history.getStates()));
assertEquals(emptyHistory, HistoryUtils.toXml(history.getStates()));
state.setSaved(true);
Assert.assertEquals(toXml1, HistoryUtils.toXml(history.getStates()));
assertEquals(toXml1, HistoryUtils.toXml(history.getStates()));
calculatorDisplay = CalculatorDisplayViewStateImpl.newValidState(JsclOperation.numeric, null, "5/6", 3);
@ -184,7 +185,7 @@ public class HistoryUtilsTest {
history.addState(state);
String xml = HistoryUtils.toXml(history.getStates());
Assert.assertEquals(toXml2, xml);
assertEquals(toXml2, xml);
final List<CalculatorHistoryState> fromXml = new ArrayList<CalculatorHistoryState>();
final HistoryHelper<CalculatorHistoryState> historyFromXml = SimpleHistoryHelper.newInstance();
@ -193,7 +194,7 @@ public class HistoryUtilsTest {
historyFromXml.addState(historyState);
}
Assert.assertEquals(history.getStates().size(), historyFromXml.getStates().size());
assertEquals(history.getStates().size(), historyFromXml.getStates().size());
for (CalculatorHistoryState historyState : history.getStates()) {
historyState.setId(0);

View File

@ -22,10 +22,9 @@
package org.solovyev.android.calculator;
import junit.framework.Assert;
import javax.annotation.Nonnull;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;

View File

@ -22,8 +22,7 @@
package org.solovyev.android.calculator;
import junit.framework.Assert;
import org.junit.Assert;
import org.junit.Test;
/**

View File

@ -22,10 +22,9 @@
package org.solovyev.android.calculator.history;
import junit.framework.Assert;
import javax.annotation.Nonnull;
import org.junit.Assert;
import org.junit.BeforeClass;
import org.junit.Test;
import org.solovyev.android.calculator.CalculatorDisplayViewStateImpl;

View File

@ -22,8 +22,7 @@
package org.solovyev.android.calculator.math;
import junit.framework.Assert;
import org.junit.Assert;
import org.junit.BeforeClass;
import org.junit.Test;
import org.solovyev.android.calculator.AbstractCalculatorTest;

View File

@ -44,7 +44,8 @@ import org.solovyev.android.calculator.jscl.JsclOperation;
import java.text.DecimalFormatSymbols;
import java.util.Locale;
import static junit.framework.Assert.fail;
import static org.junit.Assert.fail;
/**
* User: serso