Commit 4cf45a52 authored by Filipa Lacerda's avatar Filipa Lacerda

Adds line number in the path

parent f7eb7336
......@@ -790,7 +790,7 @@
.mr-widget-code-quality-list {
list-style: none;
padding: 4px 36px;
padding: 0px 36px;
margin: 0;
line-height: $code_line_height;
......
......@@ -60,7 +60,7 @@
:href="issue.location.urlPath"
target="_blank"
rel="noopener noreferrer nofollow">
{{issue.location.path}}
{{issue.location.path}}<template v-if="issue.location.lines && issue.location.lines.begin">:{{issue.location.lines.begin}}</template>
</a>
</li>
</ul>
......
......@@ -22,7 +22,9 @@ describe('merge request code quality issues', () => {
path: 'bar',
urlPath: 'foo',
positions: '81',
lines: '21',
lines: {
begin: '21',
},
},
}],
});
......@@ -31,7 +33,7 @@ describe('merge request code quality issues', () => {
it('should render issue', () => {
expect(
vm.$el.querySelector('li').textContent.trim().replace(/\s+/g, ''),
).toEqual('Fixed:fooinbar');
).toEqual('Fixed:fooinbar:21');
});
});
......@@ -44,7 +46,9 @@ describe('merge request code quality issues', () => {
location: {
path: 'bar',
positions: '81',
lines: '21',
lines: {
begin: '21',
},
},
}],
});
......@@ -65,7 +69,9 @@ describe('merge request code quality issues', () => {
location: {
path: 'bar',
positions: '81',
lines: '21',
lines: {
begin: '21',
},
},
}],
});
......
......@@ -268,4 +268,4 @@ export const baseIssues = [
},
"fingerprint": "ca2354534dee94ae60ba2f54e3857c50e5",
}
]
];
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment