prettier/tests/flow/declaration_files_increment.../__snapshots__/jsfmt.spec.js.snap

36 lines
993 B
Plaintext

// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`A.js 1`] = `
/* @flow */
class AImplementation {}
export function foo(): AImplementation { return new AImplementation(); }
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/* @flow */
class AImplementation {}
export function foo(): AImplementation {
return new AImplementation();
}
`;
exports[`index.js 1`] = `
/* @flow */
var A = require('A');
(A.foo(): boolean); // Error: Either AImplementation ~> boolean or ADefinition ~> boolean
var test = require('test');
(test.foo(): boolean); // Error: Either TestImplementation ~> boolean or TestDefinition ~> boolean
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/* @flow */
var A = require("A");
(A.foo(): boolean); // Error: Either AImplementation ~> boolean or ADefinition ~> boolean
var test = require("test");
(test.foo(): boolean); // Error: Either TestImplementation ~> boolean or TestDefinition ~> boolean
`;