public static void GetStream()
{
var manager = new ResourceManager("System.Resources.Tests.Resources.TestResx.netstandard17", typeof(ResourceManagerTests).GetTypeInfo().Assembly);
var culture = new CultureInfo("en-US");
var expectedBytes = new byte[] { 41, 42, 43, 44, 192, 168, 1, 1 };
using (Stream stream = manager.GetStream("ByteStream"))
{
foreach (byte b in expectedBytes)
{
Assert.Equal(b, stream.ReadByte());
}
}
using (Stream stream = manager.GetStream("ByteStream", culture))
{
foreach (byte b in expectedBytes)
{
Assert.Equal(b, stream.ReadByte());
}
}
}
}