Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion _episodes/41-code-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ keypoints:
- "Code review is a team software quality assurance practice where team members look at parts of the codebase in order to improve their code's readability, understandability, quality and maintainability."
- "It is important to agree on a set of best practices and establish a code review process in a team to help to
sustain a good, stable and maintainable code for many years."
layout: lesson_mermaid
---

## Introduction
Expand Down Expand Up @@ -178,7 +179,23 @@ didn't see before!

Here is an outline of the process of a tool based code review that we will be following:

![Code review timeline](../fig/code-review-timeline.png){: width="560px"}
```mermaid
%% Must disable useMaxWidth to have the diagram centre
%%{init: { 'sequence': {'useMaxWidth':false} } }%%
sequenceDiagram
participant A as Author
participant R as Reviewer
A->>A: Write some code
A->>R: Raise a pull request
R->>R: Add comments to a review
R->>A: Submit a review
loop Until approved
A->>R: Address or respond to review comments
R->>A: Clarify or resolve comments
end
R->>A: Approve pull request
A->>A: Merge pull request
```

Recall [solution requirements SR1.1.1](../31-software-requirements/index.html#solution-requirements)
from an earlier episode.
Expand Down
22 changes: 22 additions & 0 deletions _layouts/lesson_mermaid.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
layout: lesson
---
{{ content }}
<script src="https://unpkg.com/mermaid@8.9.3/dist/mermaid.min.js"></script>
<script>
document.addEventListener("DOMContentLoaded", function(){
mermaid.initialize({
startOnLoad:true,
theme: "default",
});
window.mermaid.init(undefined, document.querySelectorAll('.language-mermaid'));
});
</script>
<!--Below styling is required to centre the SVG -->
<style>
.language-mermaid>svg {
background-color: white;
width: 100%;
margin: auto;
}
</style>
15 changes: 0 additions & 15 deletions fig/code-review-timeline.mermaid.txt

This file was deleted.

Binary file removed fig/code-review-timeline.png
Binary file not shown.