@@ -10,9 +10,12 @@ import {
1010} from '../tools/helpers' ;
1111
1212const DOMAIN = 'FtDomain' ;
13+ const INLINE_DOMAIN = 'FtDomainInline' ;
1314const O2M_OBJECT = 'FtRelationshipO2m' ;
1415const M2M_OBJECT = 'FtRelationshipM2m' ;
1516const M2M_CHILD_OBJECT = 'FtM2mChild' ;
17+ const INLINE_OBJECT = 'FtObjInlineParent' ;
18+ const INLINE_CHILD = 'FtObjInlineChild' ;
1619
1720const O2M_FORM = '#form_FtRelationshipO2m_the_ajax_FtRelationshipO2m_0' ;
1821const O2M_CHILD_PANEL = '#list_FtO2mChild_panel_ajax_FtO2mChild_ftO2mcO2mId' ;
@@ -51,7 +54,7 @@ test('FT_0104', {
5154 await childPanel . locator ( "[data-action='create']" ) . click ( ) ;
5255 await skeletonDismissed ( page ) ;
5356
54- await expect ( page . locator ( '#field_ftO2mcO2mId__ftO2mCode' ) ) . toContainText ( o2mCode ) ;
57+ await expect ( page . locator ( '#field_ftO2mcO2mId__ftO2mCode' ) ) . toHaveValue ( o2mCode ) ;
5558 const childCode = randomString ( 10 ) ;
5659 await page . locator ( '#field_ftO2mcCode' ) . fill ( childCode ) ;
5760 await page . locator ( "[data-action='saveclose']" ) . click ( ) ;
@@ -98,3 +101,26 @@ test('FT_0107', {
98101
99102 await expect ( page . locator ( `[data-list='${ M2M_PANEL_LIST_DATA } '] tr` ) ) . toHaveCount ( 2 ) ;
100103} ) ;
104+
105+
106+ test ( 'FT_0103' , {
107+ annotation : {
108+ type : 'feature' ,
109+ description : 'Creates a parent with an inlined child object, fills parent and child fields, saves, and verifies parent description is updated by child hooks.'
110+ } ,
111+ } , async ( { page } ) => {
112+ await openList ( page , INLINE_DOMAIN , INLINE_OBJECT ) ;
113+
114+ await page . locator ( "[data-action='create']" ) . click ( ) ;
115+ await skeletonDismissed ( page ) ;
116+
117+ await expect ( page . locator ( `[data-object='${ INLINE_CHILD } ']` ) ) . toHaveAttribute ( 'data-rowid' , '0' ) ;
118+ await page . locator ( "#field_ftObjInlineParentName" ) . fill ( randomString ( 10 ) ) ;
119+ await page . locator ( "#field_ftObjInlineName_idftObjInlineChildParentId" ) . fill ( randomString ( 10 ) ) ;
120+
121+ await page . locator ( "[data-action='save']" ) . click ( ) ;
122+ await expect ( page . locator ( "#field_ftObjInlineParentDescription" ) ) . toHaveValue ( "Updated by child postCreate" ) ;
123+
124+ await page . locator ( "[data-action='save']" ) . click ( ) ;
125+ await expect ( page . locator ( "#field_ftObjInlineParentDescription" ) ) . toHaveValue ( "Updated by child postUpdate" ) ;
126+ } ) ;
0 commit comments