mirror of
https://github.com/hanzo-studio/studio-frontend.git
synced 2026-10-30 18:55:56 +00:00
- Replace all ComfyUI references with Hanzo Studio - Update comfy.org URLs to hanzo.ai/studio.hanzo.ai - Change comfyanonymous to hanzoai - Update Comfy-Org to hanzo-studio - Rename files and directories - Update package names and configurations - Update documentation and README files This is a comprehensive rebranding to align with Hanzo AI's product suite and company identity.
259 lines
5.9 KiB
TypeScript
259 lines
5.9 KiB
TypeScript
/**
|
|
* @fileoverview Test fixtures for history V2 timestamp-based sorting
|
|
*/
|
|
import type { HistoryResponseV2 } from '@/platform/remote/hanzo-studio/history/types/historyV2Types'
|
|
|
|
export const historyV2WithMissingTimestamp: HistoryResponseV2 = {
|
|
history: [
|
|
{
|
|
prompt_id: 'item-timestamp-1000',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-timestamp-1000',
|
|
extra_data: {
|
|
client_id: 'test-client'
|
|
}
|
|
},
|
|
outputs: {
|
|
'1': {
|
|
images: [{ filename: 'test1.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: [
|
|
[
|
|
'execution_success',
|
|
{ prompt_id: 'item-timestamp-1000', timestamp: 1000 }
|
|
]
|
|
]
|
|
}
|
|
},
|
|
{
|
|
prompt_id: 'item-timestamp-2000',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-timestamp-2000',
|
|
extra_data: {
|
|
client_id: 'test-client'
|
|
}
|
|
},
|
|
outputs: {
|
|
'2': {
|
|
images: [{ filename: 'test2.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: [
|
|
[
|
|
'execution_success',
|
|
{ prompt_id: 'item-timestamp-2000', timestamp: 2000 }
|
|
]
|
|
]
|
|
}
|
|
},
|
|
{
|
|
prompt_id: 'item-no-timestamp',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-no-timestamp',
|
|
extra_data: {
|
|
client_id: 'test-client'
|
|
}
|
|
},
|
|
outputs: {
|
|
'3': {
|
|
images: [{ filename: 'test3.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: []
|
|
}
|
|
}
|
|
]
|
|
}
|
|
|
|
export const historyV2FiveItemsSorting: HistoryResponseV2 = {
|
|
history: [
|
|
{
|
|
prompt_id: 'item-timestamp-3000',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-timestamp-3000',
|
|
extra_data: { client_id: 'test-client' }
|
|
},
|
|
outputs: {
|
|
'1': {
|
|
images: [{ filename: 'test1.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: [
|
|
[
|
|
'execution_success',
|
|
{ prompt_id: 'item-timestamp-3000', timestamp: 3000 }
|
|
]
|
|
]
|
|
}
|
|
},
|
|
{
|
|
prompt_id: 'item-timestamp-1000',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-timestamp-1000',
|
|
extra_data: { client_id: 'test-client' }
|
|
},
|
|
outputs: {
|
|
'2': {
|
|
images: [{ filename: 'test2.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: [
|
|
[
|
|
'execution_success',
|
|
{ prompt_id: 'item-timestamp-1000', timestamp: 1000 }
|
|
]
|
|
]
|
|
}
|
|
},
|
|
{
|
|
prompt_id: 'item-timestamp-5000',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-timestamp-5000',
|
|
extra_data: { client_id: 'test-client' }
|
|
},
|
|
outputs: {
|
|
'3': {
|
|
images: [{ filename: 'test3.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: [
|
|
[
|
|
'execution_success',
|
|
{ prompt_id: 'item-timestamp-5000', timestamp: 5000 }
|
|
]
|
|
]
|
|
}
|
|
},
|
|
{
|
|
prompt_id: 'item-timestamp-2000',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-timestamp-2000',
|
|
extra_data: { client_id: 'test-client' }
|
|
},
|
|
outputs: {
|
|
'4': {
|
|
images: [{ filename: 'test4.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: [
|
|
[
|
|
'execution_success',
|
|
{ prompt_id: 'item-timestamp-2000', timestamp: 2000 }
|
|
]
|
|
]
|
|
}
|
|
},
|
|
{
|
|
prompt_id: 'item-timestamp-4000',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-timestamp-4000',
|
|
extra_data: { client_id: 'test-client' }
|
|
},
|
|
outputs: {
|
|
'5': {
|
|
images: [{ filename: 'test5.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: [
|
|
[
|
|
'execution_success',
|
|
{ prompt_id: 'item-timestamp-4000', timestamp: 4000 }
|
|
]
|
|
]
|
|
}
|
|
}
|
|
]
|
|
}
|
|
|
|
export const historyV2MultipleNoTimestamp: HistoryResponseV2 = {
|
|
history: [
|
|
{
|
|
prompt_id: 'item-no-timestamp-1',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-no-timestamp-1',
|
|
extra_data: { client_id: 'test-client' }
|
|
},
|
|
outputs: {
|
|
'1': {
|
|
images: [{ filename: 'test1.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: []
|
|
}
|
|
},
|
|
{
|
|
prompt_id: 'item-no-timestamp-2',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-no-timestamp-2',
|
|
extra_data: { client_id: 'test-client' }
|
|
},
|
|
outputs: {
|
|
'2': {
|
|
images: [{ filename: 'test2.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: []
|
|
}
|
|
},
|
|
{
|
|
prompt_id: 'item-no-timestamp-3',
|
|
prompt: {
|
|
priority: 0,
|
|
prompt_id: 'item-no-timestamp-3',
|
|
extra_data: { client_id: 'test-client' }
|
|
},
|
|
outputs: {
|
|
'3': {
|
|
images: [{ filename: 'test3.png', type: 'output', subfolder: '' }]
|
|
}
|
|
},
|
|
status: {
|
|
status_str: 'success',
|
|
completed: true,
|
|
messages: []
|
|
}
|
|
}
|
|
]
|
|
}
|