Skip to content

Commit 69858cf

Browse files
authored
test(bytes): fix typo in test description (#6179)
1 parent bf0ad52 commit 69858cf

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

bytes/index_of_needle_test.ts

+6-6
Original file line numberDiff line numberDiff line change
@@ -2,31 +2,31 @@
22
import { indexOfNeedle } from "./index_of_needle.ts";
33
import { assertEquals } from "@std/assert";
44

5-
Deno.test("indexOfNeedle() handles repeating occurence", () => {
5+
Deno.test("indexOfNeedle() handles repeating occurrence", () => {
66
const i = indexOfNeedle(
77
new Uint8Array([1, 2, 0, 1, 2, 0, 1, 2, 0, 1, 3]),
88
new Uint8Array([0, 1, 2]),
99
);
1010
assertEquals(i, 2);
1111
});
1212

13-
Deno.test("indexOfNeedle() handles single occurence", () => {
13+
Deno.test("indexOfNeedle() handles single occurrence", () => {
1414
const i = indexOfNeedle(new Uint8Array([0, 0, 1]), new Uint8Array([0, 1]));
1515
assertEquals(i, 1);
1616
});
1717

18-
Deno.test("indexOfNeedle() handles text encoded occurence", () => {
18+
Deno.test("indexOfNeedle() handles text encoded occurrence", () => {
1919
const encoder = new TextEncoder();
2020
const i = indexOfNeedle(encoder.encode("Deno"), encoder.encode("D"));
2121
assertEquals(i, 0);
2222
});
2323

24-
Deno.test("indexOfNeedle() handles missing occurence", () => {
24+
Deno.test("indexOfNeedle() handles missing occurrence", () => {
2525
const i = indexOfNeedle(new Uint8Array(), new Uint8Array([0, 1]));
2626
assertEquals(i, -1);
2727
});
2828

29-
Deno.test("indexOfNeedle() returns index of occurence after start", () => {
29+
Deno.test("indexOfNeedle() returns index of occurrence after start", () => {
3030
const i = indexOfNeedle(
3131
new Uint8Array([0, 1, 2, 0, 1, 2]),
3232
new Uint8Array([0, 1]),
@@ -35,7 +35,7 @@ Deno.test("indexOfNeedle() returns index of occurence after start", () => {
3535
assertEquals(i, 3);
3636
});
3737

38-
Deno.test("indexOfNeedle() returns -1 if occurence is before start", () => {
38+
Deno.test("indexOfNeedle() returns -1 if occurrence is before start", () => {
3939
const i = indexOfNeedle(
4040
new Uint8Array([0, 1, 2, 0, 1, 2]),
4141
new Uint8Array([0, 1]),

bytes/last_index_of_needle_test.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,28 +2,28 @@
22
import { assertEquals } from "@std/assert";
33
import { lastIndexOfNeedle } from "./last_index_of_needle.ts";
44

5-
Deno.test("lastIndexOfNeedle1() handles repeating occurence", () => {
5+
Deno.test("lastIndexOfNeedle() handles repeating occurrence", () => {
66
const i = lastIndexOfNeedle(
77
new Uint8Array([0, 1, 2, 0, 1, 2, 0, 1, 3]),
88
new Uint8Array([0, 1, 2]),
99
);
1010
assertEquals(i, 3);
1111
});
1212

13-
Deno.test("lastIndexOfNeedle() handles single occurence", () => {
13+
Deno.test("lastIndexOfNeedle() handles single occurrence", () => {
1414
const i = lastIndexOfNeedle(
1515
new Uint8Array([0, 1, 1]),
1616
new Uint8Array([0, 1]),
1717
);
1818
assertEquals(i, 0);
1919
});
2020

21-
Deno.test("lastIndexOfNeedle() handles missing occurence", () => {
21+
Deno.test("lastIndexOfNeedle() handles missing occurrence", () => {
2222
const i = lastIndexOfNeedle(new Uint8Array(), new Uint8Array([0, 1]));
2323
assertEquals(i, -1);
2424
});
2525

26-
Deno.test("lastIndexOfNeedle() returns index of occurence after start", () => {
26+
Deno.test("lastIndexOfNeedle() returns index of occurrence after start", () => {
2727
const i = lastIndexOfNeedle(
2828
new Uint8Array([0, 1, 2, 0, 1, 2]),
2929
new Uint8Array([0, 1]),

0 commit comments

Comments
 (0)