File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed
webview/src/experiments/components Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -1068,6 +1068,18 @@ describe('App', () => {
10681068 } )
10691069 } )
10701070
1071+ it ( 'should not enable the user to share an experiment whilst an experiment is running' , ( ) => {
1072+ renderTable ( )
1073+
1074+ const target = screen . getByText ( '4fb124a' )
1075+ fireEvent . contextMenu ( target , { bubbles : true } )
1076+
1077+ advanceTimersByTime ( 100 )
1078+ const menuitems = screen . getAllByRole ( 'menuitem' )
1079+ const itemLabels = menuitems . map ( item => item . textContent )
1080+ expect ( itemLabels ) . not . toContain ( 'Push' )
1081+ } )
1082+
10711083 it ( 'should always present the Plots options if multiple rows are selected' , ( ) => {
10721084 renderTableWithoutRunningExperiments ( )
10731085
Original file line number Diff line number Diff line change @@ -211,7 +211,7 @@ const getSingleSelectMenuOptions = (
211211 [ id ] ,
212212 'Push' ,
213213 MessageFromWebviewType . PUSH_EXPERIMENT ,
214- isNotExperiment ,
214+ isNotExperiment || hasRunningExperiment ,
215215 true
216216 ) ,
217217 ...getRunResumeOptions (
You can’t perform that action at this time.
0 commit comments