Skip to content

Commit b0cf544

Browse files
authored
Spelling (#2398)
* spelling: accessor Signed-off-by: Josh Soref <[email protected]> * spelling: active Signed-off-by: Josh Soref <[email protected]> * spelling: addressing Signed-off-by: Josh Soref <[email protected]> * spelling: arguments Signed-off-by: Josh Soref <[email protected]> * spelling: behavior Signed-off-by: Josh Soref <[email protected]> * spelling: configurable Signed-off-by: Josh Soref <[email protected]> * spelling: expectation Signed-off-by: Josh Soref <[email protected]> * spelling: expectations Signed-off-by: Josh Soref <[email protected]> * spelling: falsy Signed-off-by: Josh Soref <[email protected]> * spelling: function Signed-off-by: Josh Soref <[email protected]> * spelling: immediate Signed-off-by: Josh Soref <[email protected]> * spelling: individual Signed-off-by: Josh Soref <[email protected]> * spelling: inherited Signed-off-by: Josh Soref <[email protected]> * spelling: maximilian Signed-off-by: Josh Soref <[email protected]> * spelling: occurred Signed-off-by: Josh Soref <[email protected]> * spelling: output Signed-off-by: Josh Soref <[email protected]> * spelling: prototype Signed-off-by: Josh Soref <[email protected]> * spelling: receive Signed-off-by: Josh Soref <[email protected]> * spelling: sandbox Signed-off-by: Josh Soref <[email protected]> * spelling: separate Signed-off-by: Josh Soref <[email protected]> * spelling: specifier Signed-off-by: Josh Soref <[email protected]> * spelling: superseded Signed-off-by: Josh Soref <[email protected]> * spelling: symmetric Signed-off-by: Josh Soref <[email protected]> * spelling: targeting Signed-off-by: Josh Soref <[email protected]> * spelling: the Signed-off-by: Josh Soref <[email protected]> * spelling: unrelated Signed-off-by: Josh Soref <[email protected]> Co-authored-by: Josh Soref <[email protected]>
1 parent e78a670 commit b0cf544

17 files changed

+44
-44
lines changed

CHANGES.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
## 11.1.2
44

55
- Upgrade @sinonjs/fake-timers to latest, see https://github.com/sinonjs/fake-timers/blob/master/CHANGELOG.md#712--2021-05-28
6-
- Copy over acessor properties to target object #2387
6+
- Copy over accessor properties to target object #2387
77

88
## 11.1.1
99

@@ -289,7 +289,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
289289

290290
## 5.1.1
291291

292-
- Remove ES2015 'module' field for 5x branch (fix in seperate branch - see tag)
292+
- Remove ES2015 'module' field for 5x branch (fix in separate branch - see tag)
293293

294294
## 5.1.0
295295

@@ -526,7 +526,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
526526

527527
## 2.3.1
528528

529-
- Make calledAfter symetric with calledBefore (#1407)
529+
- Make calledAfter symmetric with calledBefore (#1407)
530530

531531
## 2.3.0
532532

@@ -843,7 +843,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
843843
- Add support for es6 Symbol to wrapMethod method
844844
- Convert values to strings with toString instead of String()
845845
- Add typeOf matcher for symbol type
846-
- Make expectetation fail as expected when called with wrong Symbol
846+
- Make expectation fail as expected when called with wrong Symbol
847847
- Make mock report expected TypeError when expecting number and given symbol
848848
- Add support for es6 Symbol to match.has method
849849
- Make error message when failing to stub method support es6 symbol
@@ -998,7 +998,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
998998
- cleaning up left over blank lines
999999
- CommonJS-ified _some_ of the things
10001000
- updated readyStateChange to align to the w3c spec (somewhat)
1001-
- cleaned up a few unreleated tests
1001+
- cleaned up a few unrelated tests
10021002
- updated tests to reflect reality
10031003
- added some additional progress event verification
10041004
- added a test to ensure load is not fired before abort
@@ -1015,7 +1015,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
10151015

10161016
## 1.17.0
10171017

1018-
- Fix #821 where Sinon.JS would leak a setImmdiate into global scope
1018+
- Fix #821 where Sinon.JS would leak a setImmediate into global scope
10191019
- Removed sinon-timers from the build. refs #811
10201020
- Added flag that, when set to true, makes sinon.logError throw errors synchronously.
10211021
- Fix #777: Support non-enumerable props when stubbing objects
@@ -1183,7 +1183,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
11831183
- Update call properties even if exceptions are thrown (Tim Perry)
11841184
- Reverse matching order for fake server (Gordon L. Hempton)
11851185
- Fix restoring globals on another frame fails on Firefox (Burak Yiğit Kaya)
1186-
- Handle stubbing falsey properties (Tim Perry)
1186+
- Handle stubbing falsy properties (Tim Perry)
11871187
- Set returnValues correctly when the spied function is called as a constructor (Tim Perry)
11881188
- When creating a sandbox, do not overwrite existing properties when inject
11891189
properties into an object (Sergio Cinos)
@@ -1251,7 +1251,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
12511251
- Ensure window.Image can be stubbed. (Adrian Phinney)
12521252
- Fix spy() in IE 8 (Scott Andrews)
12531253
- Fix sinon base in IE 8 (Scott Andrews)
1254-
- Format arguments ouput when mock excpetation is not met (kbackowski)
1254+
- Format arguments output when mock expectation is not met (kbackowski)
12551255
- Calling spy.reset directly from stub.reset (Thomas Meyer)
12561256

12571257
## 1.5.0
@@ -1279,7 +1279,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
12791279

12801280
## 1.4.0
12811281

1282-
- Argument matchers (Maximillian Antoni)
1282+
- Argument matchers (Maximilian Antoni)
12831283
sinon.match.{any, same, typeOf, instanceOf, has, hasOwn, defined, truthy,
12841284
falsy} as well as typeOf shortcuts for boolean, number, string, object,
12851285
function, array, regexp and date. The result of a call can be used with
@@ -1413,7 +1413,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
14131413
yieldsTo can invoke callbacks in object "options" arguments.
14141414
- Allow sandboxes/collections to stub any property so long as the object
14151415
has the property as an own property
1416-
- Significantly improve error reporting from failed mock expecations. Now prints
1416+
- Significantly improve error reporting from failed mock expectations. Now prints
14171417
all met and unmet expectations with expected and received arguments
14181418
- Allow mock expectations to be consumed in any order
14191419
- Add pretty printing of all calls when assertions fail

docs/_howto/stub-dependency.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ layout: page
33
title: How to stub a dependency of a module
44
---
55

6-
Sinon is a stubbing library, not a module interception library. Stubbing dependencies is highly dependant on your enviroment and the implementation. For Node environments, we usually recommend solutions targetting [link seams](../link-seams-commonjs/) or explicit dependency injection. Though in some more basic cases, you can get away with only using Sinon by modifying the module exports of the dependency.
6+
Sinon is a stubbing library, not a module interception library. Stubbing dependencies is highly dependant on your enviroment and the implementation. For Node environments, we usually recommend solutions targeting [link seams](../link-seams-commonjs/) or explicit dependency injection. Though in some more basic cases, you can get away with only using Sinon by modifying the module exports of the dependency.
77

88
To stub a dependency (imported module) of a module under test you have to import it explicitly in your test and stub the desired method. For the stubbing to work, the stubbed method cannot be [destructured](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Destructuring_assignment), neither in the module under test nor in the test.
99

docs/_sass/bootstrap/_input-groups.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@
138138
font-size: 0;
139139
white-space: nowrap;
140140

141-
// Negative margin for spacing, position for bringing hovered/focused/actived
141+
// Negative margin for spacing, position for bringing hovered/focused/active
142142
// element above the siblings.
143143
> .btn {
144144
position: relative;

docs/changelog.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ permalink: /releases/changelog
99
==================
1010

1111
* Upgrade @sinonjs/fake-timers to latest, see https://github.com/sinonjs/fake-timers/blob/master/CHANGELOG.md#712--2021-05-28
12-
* Copy over acessor properties to target object #2387
12+
* Copy over accessor properties to target object #2387
1313

1414
11.1.1 / 2021-05-26
1515
==================
@@ -351,7 +351,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
351351
5.1.1 / 2018-06-07
352352
==================
353353

354-
* Remove ES2015 'module' field for 5x branch (fix in seperate branch - see tag)
354+
* Remove ES2015 'module' field for 5x branch (fix in separate branch - see tag)
355355

356356
5.1.0 / 2018-06-06
357357
==================
@@ -640,7 +640,7 @@ The major release is caused by removing old mistakes and upgrading dependencies
640640
2.3.1 / 2017-05-23
641641
==================
642642

643-
* Make calledAfter symetric with calledBefore (#1407)
643+
* Make calledAfter symmetric with calledBefore (#1407)
644644

645645
2.3.0 / 2017-05-22
646646
==================
@@ -972,7 +972,7 @@ v2.0.0-pre.5 / 2016-12-31
972972
* Add support for es6 Symbol to wrapMethod method
973973
* Convert values to strings with toString instead of String()
974974
* Add typeOf matcher for symbol type
975-
* Make expectetation fail as expected when called with wrong Symbol
975+
* Make expectation fail as expected when called with wrong Symbol
976976
* Make mock report expected TypeError when expecting number and given symbol
977977
* Add support for es6 Symbol to match.has method
978978
* Make error message when failing to stub method support es6 symbol
@@ -1128,7 +1128,7 @@ v2.0.0-pre.5 / 2016-12-31
11281128
* cleaning up left over blank lines
11291129
* CommonJS-ified *some* of the things
11301130
* updated readyStateChange to align to the w3c spec (somewhat)
1131-
* cleaned up a few unreleated tests
1131+
* cleaned up a few unrelated tests
11321132
* updated tests to reflect reality
11331133
* added some additional progress event verification
11341134
* added a test to ensure load is not fired before abort
@@ -1146,7 +1146,7 @@ v2.0.0-pre.5 / 2016-12-31
11461146
1.17.0 / 2015-09-22
11471147
==================
11481148

1149-
* Fix #821 where Sinon.JS would leak a setImmdiate into global scope
1149+
* Fix #821 where Sinon.JS would leak a setImmediate into global scope
11501150
* Removed sinon-timers from the build. refs #811
11511151
* Added flag that, when set to true, makes sinon.logError throw errors synchronously.
11521152
* Fix #777: Support non-enumerable props when stubbing objects
@@ -1309,7 +1309,7 @@ v2.0.0-pre.5 / 2016-12-31
13091309
* Update call properties even if exceptions are thrown (Tim Perry)
13101310
* Reverse matching order for fake server (Gordon L. Hempton)
13111311
* Fix restoring globals on another frame fails on Firefox (Burak Yiğit Kaya)
1312-
* Handle stubbing falsey properties (Tim Perry)
1312+
* Handle stubbing falsy properties (Tim Perry)
13131313
* Set returnValues correctly when the spied function is called as a constructor (Tim Perry)
13141314
* When creating a sandbox, do not overwrite existing properties when inject
13151315
properties into an object (Sergio Cinos)
@@ -1374,7 +1374,7 @@ v2.0.0-pre.5 / 2016-12-31
13741374
* Ensure window.Image can be stubbed. (Adrian Phinney)
13751375
* Fix spy() in IE 8 (Scott Andrews)
13761376
* Fix sinon base in IE 8 (Scott Andrews)
1377-
* Format arguments ouput when mock excpetation is not met (kbackowski)
1377+
* Format arguments output when mock expectation is not met (kbackowski)
13781378
* Calling spy.reset directly from stub.reset (Thomas Meyer)
13791379

13801380
== 1.5.0 / 2012-10-19
@@ -1398,7 +1398,7 @@ v2.0.0-pre.5 / 2016-12-31
13981398
(which provides a shim process object)
13991399

14001400
== 1.4.0 / 2012-07-09
1401-
* Argument matchers (Maximillian Antoni)
1401+
* Argument matchers (Maximilian Antoni)
14021402
sinon.match.{any, same, typeOf, instanceOf, has, hasOwn, defined, truthy,
14031403
falsy} as well as typeOf shortcuts for boolean, number, string, object,
14041404
function, array, regexp and date. The result of a call can be used with
@@ -1526,7 +1526,7 @@ v2.0.0-pre.5 / 2016-12-31
15261526
yieldsTo can invoke callbacks in object "options" arguments.
15271527
* Allow sandboxes/collections to stub any property so long as the object
15281528
has the property as an own property
1529-
* Significantly improve error reporting from failed mock expecations. Now prints
1529+
* Significantly improve error reporting from failed mock expectations. Now prints
15301530
all met and unmet expectations with expected and received arguments
15311531
* Allow mock expectations to be consumed in any order
15321532
* Add pretty printing of all calls when assertions fail

docs/release-source/release/fake-xhr-and-server.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ Causes all queued asynchronous requests to receive a response.
284284

285285
If none of the responses added through `respondWith()` match, the default response is `[404, {}, ""]`.
286286

287-
Synchronous requests are responded to immediately so make sure to call `respondWith()` to configure the server response before calling `respond()`. If not, you will recieve the default `404 NOT FOUND` response.
287+
Synchronous requests are responded to immediately so make sure to call `respondWith()` to configure the server response before calling `respond()`. If not, you will receive the default `404 NOT FOUND` response.
288288

289289
If called with arguments, `respondWith()` will be called with those arguments before responding to requests.
290290

docs/release-source/release/spy-call.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ breadcrumb: spy-call
66

77
## Spy call
88

9-
A spy call is an object representation of an invididual call to a _spied_ function, which could be a [fake](../fakes), [spy](../spies), [stub](../stubs) or [mock method](../mocks).
9+
A spy call is an object representation of an individual call to a _spied_ function, which could be a [fake](../fakes), [spy](../spies), [stub](../stubs) or [mock method](../mocks).
1010

1111
### `var spyCall = spy.getCall(n)`
1212

docs/release-source/release/utils.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Sinon.JS has a few utilities used internally in `lib/sinon.js`. Unless the metho
1010

1111
#### `sinon.createStubInstance(constructor);`
1212

13-
Creates a new object with the given function as the protoype and stubs all implemented functions.
13+
Creates a new object with the given function as the prototype and stubs all implemented functions.
1414

1515
```javascript
1616
class Container {

docs/releases.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ <h2 id="npm-cdns">Using NPM based CDNs</h2>
5454
<a href="https://cdnjs.com">cdnjs</a>.
5555
</p>
5656
<p>
57-
Their adressing schemes vary, but an example url such as
57+
Their addressing schemes vary, but an example url such as
5858
<a href="https://cdn.jsdelivr.net/npm/sinon@3/pkg/sinon.js"
5959
>https://cdn.jsdelivr.net/npm/sinon@3/pkg/sinon.js</a
6060
>

lib/sinon/promise.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ var STATUS_RESOLVED = "resolved";
88
var STATUS_REJECTED = "rejected";
99

1010
/**
11-
* Returns a fake for a given function or undefined. If no functino is given, a
11+
* Returns a fake for a given function or undefined. If no function is given, a
1212
* new fake is returned. If the given function is already a fake, it is
1313
* returned as is. Otherwise the given function is wrapped in a new fake.
1414
*

lib/sinon/proxy.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -120,16 +120,16 @@ var proxyApi = {
120120
var args = slice(arguments, 1);
121121
var formatter;
122122

123-
return (format || "").replace(/%(.)/g, function (match, specifyer) {
124-
formatter = proxyApi.formatters[specifyer];
123+
return (format || "").replace(/%(.)/g, function (match, specifier) {
124+
formatter = proxyApi.formatters[specifier];
125125

126126
if (typeof formatter === "function") {
127127
return String(formatter(spyInstance, args));
128-
} else if (!isNaN(parseInt(specifyer, 10))) {
129-
return sinonFormat(args[specifyer - 1]);
128+
} else if (!isNaN(parseInt(specifier, 10))) {
129+
return sinonFormat(args[specifier - 1]);
130130
}
131131

132-
return `%${specifyer}`;
132+
return `%${specifier}`;
133133
});
134134
},
135135

lib/sinon/util/core/extend.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ module.exports = function extend(target, ...sources) {
108108
};
109109
/*
110110
if the sorce has an Accessor property copy over the accessor functions (get and set)
111-
data properties has writable attribute where as acessor property don't
111+
data properties has writable attribute where as accessor property don't
112112
REF: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#properties
113113
*/
114114

test/assert-test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ describe("assert", function () {
105105
assert(sinonAssert.fail.calledOnce);
106106
});
107107

108-
it("passes when argumens match", function () {
108+
it("passes when arguments match", function () {
109109
sinonAssert.match("foo", "foo");
110110
assert(sinonAssert.pass.calledOnce);
111111
});
@@ -2322,7 +2322,7 @@ describe("assert", function () {
23222322

23232323
it(
23242324
"should indicate that an assertion failure with a symbol method name " +
2325-
"occured in exception messages, even if the symbol has no description",
2325+
"occurred in exception messages, even if the symbol has no description",
23262326
function () {
23272327
// eslint-disable-next-line symbol-description
23282328
var symbol = Symbol();

test/extend-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ describe("extend", function () {
7878
assert.equals(result, expected);
7979
});
8080

81-
it("copies acessor properties into the target", function () {
81+
it("copies accessor properties into the target", function () {
8282
var target = {
8383
hello: "hello",
8484
};

test/issues/issues-test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ describe("issues", function () {
7878
});
7979
});
8080

81-
describe("#852 - createStubInstance on intherited constructors", function () {
81+
describe("#852 - createStubInstance on inherited constructors", function () {
8282
it("must not throw error", function () {
8383
var A = function () {
8484
return;
@@ -318,7 +318,7 @@ describe("issues", function () {
318318
); //backup val
319319
Object.defineProperty(window, "innerHeight", {
320320
value: 10,
321-
configureable: true,
321+
configurable: true,
322322
writeable: true,
323323
});
324324
Object.defineProperty(window, "innerHeight", preDescriptor); //restore

test/sandbox-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1501,7 +1501,7 @@ describe("Sandbox", function () {
15011501
assert.same(setTimeout, originalSetTimeout, "fakeTimers restored");
15021502
});
15031503

1504-
it("restores spied fake timers when then sanddox is restored", function () {
1504+
it("restores spied fake timers when the sandbox is restored", function () {
15051505
var originalSetTimeout = setTimeout;
15061506

15071507
this.sandbox.useFakeTimers();

test/stub-test.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@ describe("stub", function () {
279279

280280
it("supersedes previous rejects", function () {
281281
var stub = createStub();
282-
stub.rejects(Error("should be superseeded")).resolves(1);
282+
stub.rejects(Error("should be superseded")).resolves(1);
283283

284284
return stub().then();
285285
});
@@ -546,7 +546,7 @@ describe("stub", function () {
546546

547547
it("supersedes previous rejects", function () {
548548
var stub = createStub();
549-
stub.rejects(Error("should be superseeded")).resolvesArg(1);
549+
stub.rejects(Error("should be superseded")).resolvesArg(1);
550550

551551
return stub("zero", "one").then(function (actual) {
552552
assert.same(actual, "one");
@@ -720,7 +720,7 @@ describe("stub", function () {
720720
);
721721
});
722722

723-
it("should be reset by .resetBeahvior", function () {
723+
it("should be reset by .resetBehavior", function () {
724724
var stub = createStub();
725725

726726
stub.throwsArg(0);

test/util/fake-timers-test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ describe("fakeTimers.clock", function () {
186186
assert(stub.calledWithExactly("value1", 2));
187187
});
188188
} else {
189-
it("shouldn't install setImmedate", function () {
189+
it("shouldn't install setImmediate", function () {
190190
refute.isFunction(this.clock.setImmediate);
191191
});
192192
}
@@ -208,7 +208,7 @@ describe("fakeTimers.clock", function () {
208208
assert.isFalse(callback.called);
209209
});
210210
} else {
211-
it("shouldn't install clearImmedate", function () {
211+
it("shouldn't install clearImmediate", function () {
212212
refute.isFunction(this.clock.clearImmediate);
213213
});
214214
}

0 commit comments

Comments
 (0)