Examples of timeAgoCss()


Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    assertEquals("1 year ago", timeUtils.timeAgo(offset(365 * TimeUtils.ONEDAY)));
    assertEquals("13 months ago", timeUtils.timeAgo(offset(395 * TimeUtils.ONEDAY)));
    assertEquals("2 years ago", timeUtils.timeAgo(offset((2 * 365 + 30) * TimeUtils.ONEDAY)));

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }
 
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    assertEquals("13 months ago", timeUtils.timeAgo(offset(395 * TimeUtils.ONEDAY)));
    assertEquals("2 years ago", timeUtils.timeAgo(offset((2 * 365 + 30) * TimeUtils.ONEDAY)));

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }

 
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    assertEquals("2 years ago", timeUtils.timeAgo(offset((2 * 365 + 30) * TimeUtils.ONEDAY)));

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }

  @Test
 
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }

  @Test
  public void testFrequency() {
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }

  @Test
  public void testFrequency() {
    assertEquals(5, TimeUtils.convertFrequencyToMinutes("2 mins"));
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    assertEquals("1 year ago", timeUtils.timeAgo(offset(365 * TimeUtils.ONEDAY)));
    assertEquals("13 months ago", timeUtils.timeAgo(offset(395 * TimeUtils.ONEDAY)));
    assertEquals("2 years ago", timeUtils.timeAgo(offset((2 * 365 + 30) * TimeUtils.ONEDAY)));

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }
 
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    assertEquals("13 months ago", timeUtils.timeAgo(offset(395 * TimeUtils.ONEDAY)));
    assertEquals("2 years ago", timeUtils.timeAgo(offset((2 * 365 + 30) * TimeUtils.ONEDAY)));

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }

 
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    assertEquals("2 years ago", timeUtils.timeAgo(offset((2 * 365 + 30) * TimeUtils.ONEDAY)));

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }

  @Test
 
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }

  @Test
  public void testFrequency() {
View Full Code Here

Examples of com.gitblit.utils.TimeUtils.timeAgoCss()

    // css class tests
    assertEquals("age0", timeUtils.timeAgoCss(offset(1 * TimeUtils.MIN)));
    assertEquals("age0", timeUtils.timeAgoCss(offset(60 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(120 * TimeUtils.MIN)));
    assertEquals("age1", timeUtils.timeAgoCss(offset(24 * TimeUtils.ONEHOUR)));
    assertEquals("age2", timeUtils.timeAgoCss(offset(2 * TimeUtils.ONEDAY)));
  }

  @Test
  public void testFrequency() {
    assertEquals(5, TimeUtils.convertFrequencyToMinutes("2 mins", 5));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.