TestPathPatternPrompt.d.ts 933 B

123456789101112131415161718192021222324
  1. /**
  2. * Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.
  3. *
  4. * This source code is licensed under the MIT license found in the
  5. * LICENSE file in the root directory of this source tree.
  6. */
  7. /// <reference types="node" />
  8. import type { Test } from 'jest-runner';
  9. import type { Context } from 'jest-runtime';
  10. import { PatternPrompt, Prompt, ScrollOptions } from 'jest-watcher';
  11. import type SearchSource from './SearchSource';
  12. declare type SearchSources = Array<{
  13. context: Context;
  14. searchSource: SearchSource;
  15. }>;
  16. export default class TestPathPatternPrompt extends PatternPrompt {
  17. _searchSources?: SearchSources;
  18. constructor(pipe: NodeJS.WritableStream, prompt: Prompt);
  19. _onChange(pattern: string, options: ScrollOptions): void;
  20. _printPrompt(pattern: string): void;
  21. _getMatchedTests(pattern: string): Array<Test>;
  22. updateSearchSources(searchSources: SearchSources): void;
  23. }
  24. export {};