$data_table_row =
$this->database->
select('entity_test_update_data'
) ->
fields('entity_test_update_data'
) ->
condition('id', 1, '='
) ->
condition('langcode', 'ro', '='
) ->
execute() ->
fetchAllAssoc('id'
);
$this->
assertEquals('test entity - 1 - ro',
$data_table_row[1
]->name
);
$this->
assertEquals('shared table - 1 - value 1 - ro',
$data_table_row[1
]->test_multiple_properties__value1
);
$this->
assertEquals('shared table - 1 - value 2 - ro',
$data_table_row[1
]->test_multiple_properties__value2
);
$dedicated_table_name =
$table_mapping->
getFieldTableName('test_multiple_properties_multiple_values'
);
$dedicated_table_row =
$this->database->
select($dedicated_table_name) ->
fields($dedicated_table_name) ->
condition('entity_id', 1, '='
) ->
condition('langcode', 'en', '='
) ->
execute() ->
fetchAllAssoc('delta'
);
$this->
assertEquals('dedicated table - 1 - delta 0 - value 1 - en',
$dedicated_table_row[0
]->test_multiple_properties_multiple_values_value1
);
$this->
assertEquals('dedicated table - 1 - delta 0 - value 2 - en',
$dedicated_table_row[0
]->test_multiple_properties_multiple_values_value2
);
$this->
assertEquals('dedicated table - 1 - delta 1 - value 1 - en',
$dedicated_table_row[1
]->test_multiple_properties_multiple_values_value1
);
$this->
assertEquals('dedicated table - 1 - delta 1 - value 2 - en',
$dedicated_table_row[1
]->test_multiple_properties_multiple_values_value2
);