use of com.bumptech.glide.load.Options in project glide by bumptech.
the class BaseGlideUrlLoaderTest method setUp.
@SuppressWarnings("unchecked")
@Before
public void setUp() {
MockitoAnnotations.initMocks(this);
options = new Options();
urlLoader = new TestLoader(wrapped, modelCache);
}
use of com.bumptech.glide.load.Options in project glide by bumptech.
the class StreamGifDecoderTest method setUp.
@Before
public void setUp() {
MockitoAnnotations.initMocks(this);
List<ImageHeaderParser> parsers = new ArrayList<>();
parsers.add(new DefaultImageHeaderParser());
decoder = new StreamGifDecoder(parsers, byteBufferDecoder, new LruArrayPool());
options = new Options();
}
use of com.bumptech.glide.load.Options in project glide by bumptech.
the class GifDrawableBytesTranscoderTest method testReturnsBytesOfGivenGifDrawable.
@Test
public void testReturnsBytesOfGivenGifDrawable() {
for (String fakeData : new String[] { "test", "1235asfklaw3", "@$@#" }) {
ByteBuffer expected = ByteBuffer.wrap(fakeData.getBytes(Charset.defaultCharset()));
when(gifDrawable.getBuffer()).thenReturn(expected);
Resource<byte[]> transcoded = transcoder.transcode(resource, new Options());
assertArrayEquals(expected.array(), transcoded.get());
}
}
Aggregations