<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _is_replacement_allowed(self, s):
 """Tests whether replacement is allowed on given piece of HTML text."""

        if any(tag in s.parent_tags for tag in self.skipped_tags):
            return False
        if any(tag not in self.textflow_tags for tag in s.involved_tags):
            return False
        return True