This is being done in preparation for writing a format from rbspy to import into speedscope, whose internal file format is a list of stacks (111689fe13/src/storage/v1.rs (L13))
For now, speedscope will always export the evented format rather than the sampled format, but will accept either as input. I also added tests for existing versions of the file format to ensure I don't accidentally drop support for a past version of the file format.
12 lines
400 B
TypeScript
12 lines
400 B
TypeScript
import {checkProfileSnapshot} from './test-utils'
|
|
|
|
describe('importSpeedscopeProfiles', async () => {
|
|
test('0.0.1 evented profile', async () => {
|
|
await checkProfileSnapshot('./sample/profiles/speedscope/0.0.1/simple.speedscope.json')
|
|
})
|
|
|
|
test('0.1.2 sampled profile', async () => {
|
|
await checkProfileSnapshot('./sample/profiles/speedscope/0.1.2/simple-sampled.speedscope.json')
|
|
})
|
|
})
|