2017-08-05 01:10:33 +02:00
|
|
|
/// <reference path='fourslash.ts' />
|
|
|
|
|
|
|
|
// Shouldn't be able to extract a readonly property initializer outside the constructor
|
|
|
|
|
|
|
|
//// class Foo {
|
|
|
|
//// readonly prop;
|
|
|
|
//// constructor() {
|
|
|
|
//// /*a*/this.prop = 10;/*b*/
|
|
|
|
//// }
|
|
|
|
//// }
|
|
|
|
|
|
|
|
goTo.select('a', 'b')
|
2017-10-04 00:39:12 +02:00
|
|
|
verify.not.refactorAvailable('Extract Symbol', 'function_scope_0');
|
|
|
|
verify.refactorAvailable('Extract Symbol', 'function_scope_1');
|
|
|
|
verify.not.refactorAvailable('Extract Symbol', 'function_scope_2');
|