mirror of
https://github.com/wahyd4/pinpoint.git
synced 2026-08-19 09:47:27 +10:00
[강운덕] [LUCYSUS-1744] limitUtil의 패키지명 변경. web으로 이동시킴.
git-svn-id: http://svn.bds.nhncorp.com/pe/hippo-web/trunk@2795 84d0f5b1-2673-498c-a247-62c4ff18d310
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
package com.nhn.pinpoint.web.util;
|
||||
|
||||
import junit.framework.Assert;
|
||||
import org.junit.Test;
|
||||
|
||||
/**
|
||||
* @author emeroad
|
||||
*/
|
||||
public class LimitUtilsTest {
|
||||
@Test
|
||||
public void testCheckLimit() throws Exception {
|
||||
int equals = LimitUtils.checkRange(LimitUtils.MAX);
|
||||
Assert.assertEquals(equals, LimitUtils.MAX);
|
||||
|
||||
int over = LimitUtils.checkRange(LimitUtils.MAX + 1);
|
||||
Assert.assertEquals(over, LimitUtils.MAX);
|
||||
|
||||
int low = LimitUtils.checkRange(0);
|
||||
Assert.assertEquals(low, 0);
|
||||
|
||||
int negative = LimitUtils.checkRange(-1);
|
||||
Assert.assertEquals(negative, 0);
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user