Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies #253

Merged
merged 9 commits into from
Dec 27, 2023
Merged
Show file tree
Hide file tree
Changes from 8 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
6 changes: 3 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- uses: mansona/npm-lockfile-version@v1
- uses: actions/setup-node@v2
mantoni marked this conversation as resolved.
Show resolved Hide resolved
with:
node-version: "16"
node-version: "20"
mantoni marked this conversation as resolved.
Show resolved Hide resolved
- name: Cache modules
uses: actions/cache@v2
with:
Expand All @@ -39,7 +39,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
mantoni marked this conversation as resolved.
Show resolved Hide resolved
with:
node-version: "16"
node-version: "20"
mantoni marked this conversation as resolved.
Show resolved Hide resolved
- name: Cache npm
uses: actions/cache@v2
with:
Expand All @@ -63,7 +63,7 @@ jobs:

strategy:
matrix:
node-version: [14, 16, 18]
node-version: [16, 18, 20]

steps:
- uses: actions/checkout@v2
Expand Down
18 changes: 9 additions & 9 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ assert.match(
return "yeah";
},
},
"Yeah!"
"Yeah!",
); // Passes
```

Expand All @@ -340,7 +340,7 @@ assert.match(
return "yeah!";
},
},
/yeah/
/yeah/,
); // Passes
assert.match(234, /[a-z]/); // Fails
```
Expand All @@ -358,7 +358,7 @@ assert.match(
return "42";
},
},
42
42,
); // Passes
assert.match(234, 1234); // Fails
```
Expand Down Expand Up @@ -387,7 +387,7 @@ assert.match(
},
function () {
return true;
}
},
);

// Fails
Expand Down Expand Up @@ -417,7 +417,7 @@ assert.match(
},
{
name: "Chris",
}
},
);

// Fails
Expand Down Expand Up @@ -1328,23 +1328,23 @@ assert.exception(
function () {
throw new TypeError("Ooops!");
},
{ name: "TypeError" }
{ name: "TypeError" },
);

// Fails, wrong exception type
assert.exception(
function () {
throw new Error("Aww");
},
{ name: "TypeError" }
{ name: "TypeError" },
);

// Fails, wrong exception message
assert.exception(
function () {
throw new Error("Aww");
},
{ message: "Ooops!" }
{ message: "Ooops!" },
);

// Fails, wrong exception type
Expand All @@ -1358,7 +1358,7 @@ assert.exception(
}
return true;
},
"Type of exception is wrong!"
"Type of exception is wrong!",
); // with message to print, if test fails
```

Expand Down
8 changes: 4 additions & 4 deletions lib/assert-exception-unexpected-exception.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ describe("assert.exception unexpected exception", function () {
throw new Error("apple pie");
},
{ name: "TypeError" },
"Wow"
"Wow",
);
throw new Error("Expected to throw");
} catch (e) {
referee.assert.match(
e.message,
"Wow: Expected { name: 'TypeError' } but threw 'Error' ('apple pie')"
"Wow: Expected { name: 'TypeError' } but threw 'Error' ('apple pie')",
);
}
});
Expand All @@ -28,13 +28,13 @@ describe("assert.exception unexpected exception", function () {
throw new Error("apple pie");
},
{ name: "Error", message: "Aww" },
"Wow"
"Wow",
);
throw new Error("Expected to throw");
} catch (e) {
referee.assert.match(
e.message,
"Wow: Expected { name: 'Error', message: 'Aww' } but threw 'Error' ('apple pie')"
"Wow: Expected { name: 'Error', message: 'Aww' } but threw 'Error' ('apple pie')",
);
}
});
Expand Down
6 changes: 3 additions & 3 deletions lib/assert.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ describe("assert", function () {
} catch (error) {
referee.assert.equals(
error.message,
"[assert] Expected to receive at least 1 argument(s)"
"[assert] Expected to receive at least 1 argument(s)",
);
}
});
Expand Down Expand Up @@ -51,7 +51,7 @@ describe("assert", function () {
function () {
referee.assert(false);
},
{ message: "[assert] Expected false to be truthy" }
{ message: "[assert] Expected false to be truthy" },
);
});

Expand Down Expand Up @@ -110,7 +110,7 @@ describe("assert", function () {
} catch (e) {
referee.assert.equals(
e.message,
"[assert] Expected to receive at least 1 argument(s)"
"[assert] Expected to receive at least 1 argument(s)",
);
}
});
Expand Down
60 changes: 30 additions & 30 deletions lib/assertions/class-name.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ describe("assert.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[assert.className] Expected to receive at least 2 argument(s)"
"[assert.className] Expected to receive at least 2 argument(s)",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -30,11 +30,11 @@ describe("assert.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[assert.className] Expected to receive at least 2 argument(s)"
"[assert.className] Expected to receive at least 2 argument(s)",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -47,12 +47,12 @@ describe("assert.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[assert.className] Expected object to have className property"
"[assert.className] Expected object to have className property",
);
assert.equal(error.name, "AssertionError");
assert.equal(error.operator, "assert.className");
return true;
}
},
);
});

Expand All @@ -65,12 +65,12 @@ describe("assert.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[assert.className] Nope: Expected object's className to include 'item' but was ''"
"[assert.className] Nope: Expected object's className to include 'item' but was ''",
);
assert.equal(error.name, "AssertionError");
assert.equal(error.operator, "assert.className");
return true;
}
},
);
});

Expand All @@ -91,12 +91,12 @@ describe("assert.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[assert.className] Expected object's className to include 'item post' but was 'feed item'"
"[assert.className] Expected object's className to include 'item post' but was 'feed item'",
);
assert.equal(error.name, "AssertionError");
assert.equal(error.operator, "assert.className");
return true;
}
},
);
});

Expand Down Expand Up @@ -132,11 +132,11 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Expected to receive at least 2 argument(s)"
"[refute.className] Expected to receive at least 2 argument(s)",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -149,11 +149,11 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Expected to receive at least 2 argument(s)"
"[refute.className] Expected to receive at least 2 argument(s)",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -166,12 +166,12 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Expected object to have className property"
"[refute.className] Expected object to have className property",
);
assert.equal(error.name, "AssertionError");
assert.equal(error.operator, "refute.className");
return true;
}
},
);
});

Expand All @@ -184,12 +184,12 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Nope: Expected object to have className property"
"[refute.className] Nope: Expected object to have className property",
);
assert.equal(error.name, "AssertionError");
assert.equal(error.operator, "refute.className");
return true;
}
},
);
});

Expand All @@ -206,11 +206,11 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Expected object's className not to include 'item'"
"[refute.className] Expected object's className not to include 'item'",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -225,11 +225,11 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
`[refute.className] ${message}: Expected object's className not to include 'item'`
`[refute.className] ${message}: Expected object's className not to include 'item'`,
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -242,11 +242,11 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Expected object's className not to include 'item'"
"[refute.className] Expected object's className not to include 'item'",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -263,11 +263,11 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Expected object's className not to include 'item post'"
"[refute.className] Expected object's className not to include 'item post'",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -280,11 +280,11 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Expected object's className not to include 'e a d'"
"[refute.className] Expected object's className not to include 'e a d'",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand All @@ -297,11 +297,11 @@ describe("refute.className", function () {
assert.equal(error.code, "ERR_ASSERTION");
assert.equal(
error.message,
"[refute.className] Expected object's className not to include [ 'e', 'a', 'd' ]"
"[refute.className] Expected object's className not to include [ 'e', 'a', 'd' ]",
);
assert.equal(error.name, "AssertionError");
return true;
}
},
);
});

Expand Down
Loading
Loading