@Test
public void testValueOf() {

    Ranges ranges = new Ranges(newArrayList(new Range(49, 100), new Range(150, 250)));
    when(headerDelegate.fromString("bytes=49-100,150-250")).thenReturn(ranges);
    assertSame(ranges, Ranges.valueOf("bytes=49-100,150-250"));
}