mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-24 04:16:00 +08:00
Upgrade Flow to v0.56.0
Reviewed By: calebmer Differential Revision: D5958715 fbshipit-source-id: 7feda03a9540e69bf8d9b4eb89720248ff43294f
This commit is contained in:
committed by
Facebook Github Bot
parent
f368287347
commit
a16ef18a80
@@ -28,10 +28,16 @@ describe('fs mock', () => {
|
||||
it('stores content correctly', () => {
|
||||
fs.writeFileSync('/test', 'foobar', 'utf8');
|
||||
const content = fs.readFileSync('/test', 'utf8');
|
||||
/* $FlowFixMe(>=0.56.0 site=react_native_oss) This comment suppresses an
|
||||
* error found when Flow v0.56 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
expect(content).toEqual('foobar');
|
||||
});
|
||||
|
||||
it('fails on missing path', () => {
|
||||
/* $FlowFixMe(>=0.56.0 site=react_native_oss) This comment suppresses an
|
||||
* error found when Flow v0.56 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
expect(() =>
|
||||
fs.writeFileSync('/dir/test', 'foobar', 'utf8'),
|
||||
).toThrowError('ENOENT: no such file or directory');
|
||||
@@ -43,6 +49,9 @@ describe('fs mock', () => {
|
||||
fs.mkdirSync('/dir', 0o777);
|
||||
fs.writeFileSync('/dir/test', 'foobar', 'utf8');
|
||||
const content = fs.readFileSync('/dir/test', 'utf8');
|
||||
/* $FlowFixMe(>=0.56.0 site=react_native_oss) This comment suppresses an
|
||||
* error found when Flow v0.56 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
expect(content).toEqual('foobar');
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user