Test case name | Result |
---|---|
a.toLowerCase() === "application/json" | |
a.toUpperCase() === "APPLICATION/JSON" | |
a.localeCompare("application/json", undefined, c) | |
b.toLowerCase() === "application/json" | |
b.toUpperCase() === "APPLICATION/JSON" | |
b.localeCompare("application/json", undefined, c) |
Test name | Executions per second |
---|---|
a.toLowerCase() === "application/json" | 875484300.0 Ops/sec |
a.toUpperCase() === "APPLICATION/JSON" | 712980900.0 Ops/sec |
a.localeCompare("application/json", undefined, c) | 151798.3 Ops/sec |
b.toLowerCase() === "application/json" | 701440600.0 Ops/sec |
b.toUpperCase() === "APPLICATION/JSON" | 716693600.0 Ops/sec |
b.localeCompare("application/json", undefined, c) | 163292.3 Ops/sec |