mirror of
https://github.com/actions/labeler
synced 2026-05-12 05:11:14 +02:00
Fix recursive glob behavior in our npm format script command
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { checkGlobs } from '../src/labeler'
|
||||
import { checkGlobs } from "../src/labeler";
|
||||
|
||||
import * as core from "@actions/core";
|
||||
|
||||
@@ -12,15 +12,15 @@ beforeAll(() => {
|
||||
|
||||
const matchConfig = [{ any: ["*.txt"] }];
|
||||
|
||||
describe('checkGlobs', () => {
|
||||
it('returns true when our pattern does match changed files', () => {
|
||||
describe("checkGlobs", () => {
|
||||
it("returns true when our pattern does match changed files", () => {
|
||||
const changedFiles = ["foo.txt", "bar.txt"];
|
||||
const result = checkGlobs(changedFiles, matchConfig);
|
||||
|
||||
expect(result).toBeTruthy();
|
||||
});
|
||||
|
||||
it('returns false when our pattern does not match changed files', () => {
|
||||
it("returns false when our pattern does not match changed files", () => {
|
||||
const changedFiles = ["foo.docx"];
|
||||
const result = checkGlobs(changedFiles, matchConfig);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user