Change properties of Apostille to protected from private
jontey opened this issue · comments
Jonathan Tey commented
We are having issues with accessing private variables from Apostille
class when we extend the class.
Suggest changing private
properties to protected
to enable child classes to access the variables.
http://www.typescriptlang.org/docs/handbook/classes.html#understanding-protected
Al-Khawarizmi commented
you mean all private properties or few?
Jonathan Tey commented
This one in particular
[line 32]
private transactions: IReadyTransaction[] = [];
Al-Khawarizmi commented
It's highly not likely that you want to access the transactions as they are chronologically created and should not be tampered with, however for test purposes you can do this trick:
// tslint:disable-next-line:no-string-literal
expect(privateApostille['transactions'][0].type).toEqual(TransactionType.TRANSFER);