Skip to content

Commit e4428f5

Browse files
authored
Typo and syntax coloring (#4)
1 parent e845762 commit e4428f5

File tree

1 file changed

+16
-15
lines changed

1 file changed

+16
-15
lines changed

CONTRIBUTING.md

+16-15
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ to check before contributing.
66
* Tester is opinionated
77
* Tester is lightweight
88
* Tester is intuitive
9-
* Tester is consitent
9+
* Tester is consistent
1010

1111
## Dependency Management
1212
Copy dependencies to the `vendor` folder.
@@ -45,22 +45,23 @@ and ending with helper functions and helper types.
4545
Keep line length under 120 characters for code and 80 for documentation.
4646
Break lines in a way that improves readability but still keeps the code compact;
4747
for example,
48-
49-
callable.testContext.errorf(
50-
file, line, "Function call did not panic as expected.\nExpected: %s\n", expectedError)
51-
48+
```go
49+
callable.testContext.errorf(
50+
file, line, "Function call did not panic as expected.\nExpected: %s\n", expectedError)
51+
```
5252
is readable and more compact than
53-
54-
callable.testContext.errorf(
55-
file,
56-
line,
57-
"Function call did not panic as expected.\nExpected: %s\n",
58-
expectedError)
59-
53+
```go
54+
callable.testContext.errorf(
55+
file,
56+
line,
57+
"Function call did not panic as expected.\nExpected: %s\n",
58+
expectedError)
59+
```
6060
Either is definitely more readable than
61-
62-
callable.testContext.errorf(file, line,
63-
"Function call did not panic as expected.\nExpected: %s\n", expectedError)
61+
```go
62+
callable.testContext.errorf(file, line,
63+
"Function call did not panic as expected.\nExpected: %s\n", expectedError)
64+
```
6465

6566
#### Variable Names
6667
Do not prefer `c` to `lineCount`; see _Clean Code, Chapter 2: Meaningful Names_.

0 commit comments

Comments
 (0)