This repository has been archived by the owner on Feb 12, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from krux/fix/more-test-coverage
- Loading branch information
Showing
60 changed files
with
2,352 additions
and
386 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
## What does this Pull Request do? | ||
|
||
<short description> | ||
|
||
## Why is this change being made? | ||
|
||
<explain why> | ||
|
||
## Where should the reviewer start? | ||
|
||
<help orientate the reviewer> | ||
|
||
## How was this tested? How can the reviewer verify your testing? | ||
|
||
<step-by-step instructions> | ||
<preferrably, add a failing unit test in `test/bugs/issue<ISSUE_ID>.spec.js`.> | ||
|
||
## What gif best describes this PR or how it makes you feel? | ||
|
||
 | ||
|
||
## Completion checklist | ||
|
||
- [ ] The pull request has been appropriately labelled according to our conventions. | ||
- [ ] Documentation has been updated. | ||
- [ ] The change has unit & integration tests as appropriate. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
{ | ||
"preset": "google", | ||
"maximumLineLength": null, | ||
"validateQuoteMarks": { "mark": "'", "escape": true } | ||
"validateQuoteMarks": { "mark": "'", "escape": true }, | ||
"jsDoc": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
{ | ||
"title": "gpt-mock", | ||
"destination": "./docs", | ||
"lint": true, | ||
"manual": { | ||
"overview": ["./manual/Overview.md"], | ||
"installation": ["./manual/Installation.md"], | ||
"example": ["./manual/Example.md"] | ||
}, | ||
"test": { | ||
"type": "mocha", | ||
"source": "./test/unit" | ||
}, | ||
"plugins": [ | ||
{ | ||
"name": "esdoc-importpath-plugin", | ||
"option": { | ||
"replaces": [ | ||
{ | ||
"from": "^src/", | ||
"to": "dist/" | ||
} | ||
] | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# Example | ||
|
||
```javascript | ||
import GPT from 'gpt-mock'; | ||
|
||
googletag = new GPT(); | ||
googletag.cmd.push(function() { | ||
googletag.defineSlot('/Test/12345', [728, 90], 'gpt-div-1').addService(googletag.pubads()); | ||
}); | ||
|
||
googletag.cmd.push(function() { | ||
googletag.display('gpt-div-1'); | ||
}); | ||
|
||
// Vitally, you need to tell the library that it has loaded so the commands | ||
// will be executed. | ||
googletag._loaded(); | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Installation | ||
|
||
## From npm | ||
```bash | ||
npm install -D gpt-mock | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# Overview | ||
|
||
`gpt-mock` is a testing library for mocking out the `Google Publisher Tag` (`GPT`) library, so you | ||
can test your site or library for how it interacts with `GPT` without using the production library. | ||
|
||
## Author | ||
|
||
Seth Yates | ||
|
||
## License | ||
|
||
[Apache 2](../LICENSE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.