All files / app/assets/javascripts/pipelines/components/pipelines_list pipeline_triggerer.vue

100% Statements 4/4
100% Branches 2/2
100% Functions 2/2
100% Lines 4/4

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38  5x 5x                             141x         438x                              
<script>
import UserAvatarLink from '~/vue_shared/components/user_avatar/user_avatar_link.vue';
import glFeatureFlagMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
 
export default {
  components: {
    UserAvatarLink,
  },
  mixins: [glFeatureFlagMixin()],
  props: {
    pipeline: {
      type: Object,
      required: true,
    },
  },
  computed: {
    user() {
      return this.pipeline.user;
    },
  },
};
</script>
<template>
  <div class="pipeline-triggerer" data-testid="pipeline-triggerer">
    <user-avatar-link
      v-if="user"
      :link-href="user.path"
      :img-src="user.avatar_url"
      :img-size="26"
      :tooltip-text="user.name"
      class="gl-ml-3 js-pipeline-url-user"
    />
    <span v-else class="gl-ml-3 js-pipeline-url-api api">
      {{ s__('Pipelines|API') }}
    </span>
  </div>
</template>