If statements in twig
Twig blocks are named control structures, you can't define them multiple times within the same scope. Either try to move the if statement inside one single block

{% if topic_type %}
  {% embed "node--teaser__field.html.twig" %}     
    {%- block field_icon -%}
      {% if topic_type == 'test' %}
        icon 1 
      {% else %}
        icon 2 
      {% endif%}
    {%- endblock -%}
    {%- block field_value -%} {{ topic_type }} {%- endblock -%}
  {% endembed %}
{% endif %}


or don't overwrite the block at all, instead use variables and pass them down in the embed statement

{% set custom_icon = (topic_type == 'test' ? 'icon1' : 'icon2') %}
{% embed "node--teaser__field.html.twig" with {'icon': custom_icon, 'title': topic_type } %}


I'd recommend the first when there are major overwrites in the HTML output, and the 2nd when only strings/variables/placeholders are replaced.