rule(config, test) {
            return {
                exists: () => t.truthy(findWebpackRule(config, test)),

                /**
                 * @param {string|RegExp|((loader: string) => boolean)} loader
                 */
                loader: loader =>
                    this.loader(config, loader, findWebpackRule(config, test)),

                get: () => findWebpackRule(config, test)
            };
        }
Assert that a matching webpack rule can be found

@param {import("webpack").Configuration} config
@param {(rule: import("webpack").RuleSetRule) => boolean} test