26 test failures to go :D
This commit is contained in:
parent
6ad31fe023
commit
0041dae664
7 changed files with 70 additions and 10 deletions
|
@ -78,8 +78,9 @@ describe('MessagePanel', function() {
|
|||
client.credentials = {userId: '@me:here'};
|
||||
|
||||
// HACK: We assume all settings want to be disabled
|
||||
SettingsStore.getValue = jest.fn().returns(false);
|
||||
SettingsStore.getValue.withArgs('showDisplaynameChanges').returns(true);
|
||||
SettingsStore.getValue = jest.fn((arg) => {
|
||||
return arg === "showDisplaynameChanges";
|
||||
});
|
||||
|
||||
// This option clobbers the duration of all animations to be 1ms
|
||||
// which makes unit testing a lot simpler (the animation doesn't
|
||||
|
|
|
@ -69,7 +69,7 @@ describe('Login', function() {
|
|||
});
|
||||
|
||||
it('should show form without change server link when custom URLs disabled', function() {
|
||||
jest.spyOn(SdkConfig, "get").returns({
|
||||
jest.spyOn(SdkConfig, "get").mockReturnValue({
|
||||
disable_custom_urls: true,
|
||||
});
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@ describe('Registration', function() {
|
|||
});
|
||||
|
||||
it('should show form when custom URLs disabled', function() {
|
||||
jest.spyOn(SdkConfig, "get").returns({
|
||||
jest.spyOn(SdkConfig, "get").mockReturnValue({
|
||||
disable_custom_urls: true,
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue