00e35bed创建于 2024年7月18日历史提交


import std.io.*
import std.time.*
import std.fs.*
import io4cj.*

@Test
public class okio_encodeUtf8_029{

    var bs : ByteString = ByteString("123".toUtf8Array())
    public override func beforeAll(): Unit {
    }
    public override func afterAll(): Unit {
        // println("bs = ${bs.toString()}")
    }
    public override func beforeEach(): Unit {
    }
    public override func afterEach(): Unit {
        
    }
    // 返回包含UTF-8字节的新字节字符串。public static func encodeUtf8(s: String): ByteString
    @TestCase
    @Bench[1]
    func okio_encodeUtf8_029_1(): Unit {
        bs = ByteString.encodeUtf8("hello world")
    }
    @TestCase
    @Bench[10]
    func okio_encodeUtf8_029_10(): Unit {
        bs = ByteString.encodeUtf8("hello world")
    }
    @TestCase
    @Bench[100]
    func okio_encodeUtf8_029_100(): Unit {
        bs = ByteString.encodeUtf8("hello world")
    }
    @TestCase
    @Bench[1000]
    func okio_encodeUtf8_029_1000(): Unit {
        bs = ByteString.encodeUtf8("hello world")
    }
    @TestCase
    @Bench[10000]
    func okio_encodeUtf8_029_10000(): Unit {
        bs = ByteString.encodeUtf8("hello world")
    }
}