Problem/Motivation
- Configure a site with two languages
- Enable content translation and content moderation for nodes
- Create a node in language-1 with the "published" state
- Translate to language-2
- The current state will be shown as "published", which seems odd because the translation has not been added.
This was discovered in #2915398: The moderation_state field is not computed during the creation of a new entity translation..
Proposed resolution
Use hook_entity_translation_create()
to reset the moderation state.
Remaining tasks
Fix tests