Skip to content

Commit

Permalink
deps: bump @types/js-yaml from 3.12.4 to 3.12.5 (#170)
Browse files Browse the repository at this point in the history
* deps: bump @types/js-yaml from 3.12.4 to 3.12.5

Bumps [@types/js-yaml](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/js-yaml) from 3.12.4 to 3.12.5.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/js-yaml)

Signed-off-by: dependabot[bot] <support@github.com>

* fix: add any

* fix: use any

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Shohei Ueda <30958501+peaceiris@users.noreply.github.com>
  • Loading branch information
dependabot[bot] and peaceiris authored Sep 4, 2020
1 parent a94cd05 commit 41eecc4
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
6 changes: 4 additions & 2 deletions __tests__/get-inputs.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,17 @@ import yaml from 'js-yaml';

beforeEach(() => {
jest.resetModules();
const doc = yaml.safeLoad(fs.readFileSync(__dirname + '/../action.yml', 'utf8'));
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const doc: any = yaml.safeLoad(fs.readFileSync(__dirname + '/../action.yml', 'utf8'));
Object.keys(doc.inputs).forEach(name => {
const envVar = `INPUT_${name.replace(/ /g, '_').toUpperCase()}`;
process.env[envVar] = doc.inputs[name]['default'];
});
});

afterEach(() => {
const doc = yaml.safeLoad(fs.readFileSync(__dirname + '/../action.yml', 'utf8'));
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const doc: any = yaml.safeLoad(fs.readFileSync(__dirname + '/../action.yml', 'utf8'));
Object.keys(doc.inputs).forEach(name => {
const envVar = `INPUT_${name.replace(/ /g, '_').toUpperCase()}`;
delete process.env[envVar];
Expand Down
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
},
"devDependencies": {
"@types/jest": "^26.0.13",
"@types/js-yaml": "^3.12.4",
"@types/js-yaml": "^3.12.5",
"@types/mustache": "^4.0.1",
"@types/node": "~12",
"@typescript-eslint/eslint-plugin": "^4.0.0",
Expand Down
3 changes: 2 additions & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@ export async function run(): Promise<void> {
`);

const configFilePath = inps.ConfigFilePath;
const config = yaml.safeLoad(fs.readFileSync(configFilePath, 'utf8'));
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const config: any = yaml.safeLoad(fs.readFileSync(configFilePath, 'utf8'));
if (core.isDebug()) {
core.startGroup('Dump Config');
console.log(config);
Expand Down

0 comments on commit 41eecc4

Please sign in to comment.