Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 2 additions & 15 deletions src/test/components/TabSelectorMenu.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,24 +32,17 @@ describe('app/TabSelectorMenu', () => {
threadCPUDelta: 'ns',
};

// Add some frames with innerWindowIDs now. Note that we only expand the
// innerWindowID array and not the others as we don't check them at all.
// Associate the threads with innerWindowIDs now.
//
// Thread 0 will be present in firstTabTabID.
// Thread 1 be present in secondTabTabID.
profile.threads[0].frameTable.innerWindowID[0] =
extraPageData.parentInnerWindowIDsWithChildren;
profile.threads[0].frameTable.length++;
profile.threads[0].usedInnerWindowIDs = [
extraPageData.parentInnerWindowIDsWithChildren,
];

// Add a threadCPUDelta value for thread activity score.
profile.threads[0].samples.threadCPUDelta = [1];

profile.threads[1].frameTable.innerWindowID[0] =
extraPageData.secondTabInnerWindowIDs[0];
profile.threads[1].frameTable.length++;
profile.threads[1].usedInnerWindowIDs = [
extraPageData.secondTabInnerWindowIDs[0],
];
Expand Down Expand Up @@ -202,13 +195,7 @@ describe('app/TabSelectorMenu', () => {
url: removeURLs(page.url, `<Page #${index}>`),
}));

// Attach innerWindowIDs to the samples.
profile.threads[0].frameTable.innerWindowID[0] =
extraPageData.parentInnerWindowIDsWithChildren;
profile.threads[0].frameTable.length++;
profile.threads[0].frameTable.innerWindowID[1] =
extraPageData.secondTabInnerWindowIDs[0];
profile.threads[0].frameTable.length++;
// Attach innerWindowIDs to the threads.
profile.threads[0].usedInnerWindowIDs = [
extraPageData.parentInnerWindowIDsWithChildren,
extraPageData.secondTabInnerWindowIDs[0],
Expand Down
8 changes: 4 additions & 4 deletions src/test/store/profile-view.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -757,10 +757,10 @@ describe('actions/ProfileView', function () {
// use a BitSet to keep track of something that's per-stack (such as whether a stack matches
// the search filter), the BitSet needs at least two 32-bit slots.
const { profile } = getProfileFromTextSamples(`
A[lib:K][file:S] A[lib:K][file:S] A[lib:K][file:S] D[lib:nNn][file:uV] C[lib:m][file:t]
B[lib:L][file:t] B[lib:L][file:t] E[lib:O][file:Pq]
A[lib:K][file:S] A[lib:K][file:S] A[lib:K][file:S] D[lib:nNn][file:uV] C[lib:m][file:t]
B[lib:L][file:t] B[lib:L][file:t] E[lib:O][file:Pq]
A[lib:K][file:S] C[lib:m][file:t]
B[lib:L][file:t] D[lib:n][file:uV]
B[lib:L][file:t] D[lib:nNn][file:uV]
B[lib:L][file:t]
B[lib:L][file:t]
B[lib:L][file:t]
Expand Down Expand Up @@ -911,7 +911,7 @@ describe('actions/ProfileView', function () {
]);
dispatch(ProfileView.changeCallTreeSearchString('NN'));
const callTree_NN = selectedThreadSelectors.getCallTree(getState());
// Keep all stacks which include function D, which has filename nNn
// Keep all stacks which include function D, which has lib name nNn
expect(formatTree(callTree_NN)).toEqual([
'- A (total: 1, self: —)',
' - B (total: 1, self: —)',
Expand Down