[SpecFlow+ LivingDoc] Embedding images from repo in feature files
In the below documentation it is mentioned that it is possible to embed images in your feature files.
However, I can't get this to work within Azure DevOps. I've tried adding images on the same level as the feature files, but also in a subfolder. And I've also tried different paths (relative and absolute) to the images, but nothing seems to work.
I see the following broken image link in all cases:
If I look at the source of the image, I see the following URL:
And if I go to that URL, I get the following error:
So it seems that the way of referring to the branch is not correct. Is this a bug in the LivingDoc plugin? Is there a workaround?
NB: Externally published images using a URL do work though.
-
I have the same issue
0 -
Noticed this issue as well. Would be really helpful to be able to show images within DevOps.
0 -
Does it work in your master branch? The error is from a pull request.
0 -
No, that doesn't work either. I still get a broken image link.
However, I don't receive the error anymore if I open the (broken) image link in a new tab. But I'm not getting the image that I want either, just a small white image:
The source of the image from the LivingDoc now looks like this:
The {pathToImage} is the same if I navigate to the image in Azure DevOps using Repos - Files. The URL then looks like this with the same {pathToImage}:
https://dev.azure.com/{organization}/_git/{project}?path={pathToImage}
1 -
Did you by any chance find out how to fix this?
I have the exact same situation. As a work around we used external image links in the feature files instead of embedded images. Unfortunately this means we have to merge in any images before writing the feature files. It works, but I would love to see the embedded version work as well as it supports the normal PR way of working.0 -
Yes, we did find a way to fix this.
One of the issues we faced was that Google Chrome blocked the images for some reason. Might have to do with the secure network of our company. Microsoft Edge does visualize the images.
And another important thing was that the link to the image should not have indentation.
So this won't work:
Functionality: Test
TestFunctionality
But this does:
Functionality: Test
TestFunctionality
Hope this helps.
0
Please sign in to leave a comment.
Comments
6 comments