@@ -16,6 +16,7 @@ import { RegisteredCommands } from '../../commands/external'
1616import { getMarkdownString } from '../../vscode/markdownString'
1717import { DecoratableTreeItemScheme , getDecoratableUri } from '../../tree'
1818import { ExperimentStatus } from '../webview/contract'
19+ import { formatDate } from '../../util/date'
1920
2021const mockedCommands = jest . mocked ( commands )
2122mockedCommands . registerCommand = jest . fn ( )
@@ -483,8 +484,9 @@ describe('ExperimentsTree', () => {
483484 iconPath : expect . anything ( ) ,
484485 id : 'exp-123' ,
485486 label : 'a123' ,
486- tooltip :
487- '|||\n|:--|--|\n| Created | Aug 19, 2022 |\n| data/data.xml | 22a1a29 |\n| ...ms.yaml:featurize.random_value | undefined |\n' ,
487+ tooltip : `|||\n|:--|--|\n| Created | ${ formatDate (
488+ experiments [ 0 ] . Created
489+ ) } |\n| data/data.xml | 22a1a29 |\n| ...ms.yaml:featurize.random_value | undefined |\n`,
488490 type : ExperimentType . EXPERIMENT
489491 } ,
490492 {
@@ -499,8 +501,9 @@ describe('ExperimentsTree', () => {
499501 iconPath : expect . anything ( ) ,
500502 id : 'exp-456' ,
501503 label : 'b456' ,
502- tooltip :
503- '|||\n|:--|--|\n| Created | Sep 15, 2022 |\n| data/data.xml | 22a1a29 |\n| ...ms.yaml:featurize.random_value | [rbf,linear] |\n' ,
504+ tooltip : `|||\n|:--|--|\n| Created | ${ formatDate (
505+ experiments [ 1 ] . Created
506+ ) } |\n| data/data.xml | 22a1a29 |\n| ...ms.yaml:featurize.random_value | [rbf,linear] |\n`,
504507 type : ExperimentType . EXPERIMENT
505508 } ,
506509 {
@@ -515,8 +518,9 @@ describe('ExperimentsTree', () => {
515518 iconPath : expect . anything ( ) ,
516519 id : 'exp-789' ,
517520 label : 'c789' ,
518- tooltip :
519- '|||\n|:--|--|\n| Created | Jul 3, 2022 |\n| data/data.xml | 22a1a29 |\n| ...ms.yaml:featurize.random_value | false |\n' ,
521+ tooltip : `|||\n|:--|--|\n| Created | ${ formatDate (
522+ experiments [ 2 ] . Created
523+ ) } |\n| data/data.xml | 22a1a29 |\n| ...ms.yaml:featurize.random_value | false |\n`,
520524 type : ExperimentType . EXPERIMENT
521525 }
522526 ] )
0 commit comments