1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-07-30 02:21:17 +03:00

Convert synced settings to granular settings

Signed-off-by: Travis Ralston <travpc@gmail.com>
This commit is contained in:
Travis Ralston
2017-10-29 01:43:52 -06:00
parent bf815f4be9
commit ae10a11ac4
21 changed files with 177 additions and 161 deletions

View File

@ -14,6 +14,8 @@ See the License for the specific language governing permissions and
limitations under the License.
*/
import SettingsStore from "../../../src/settings/SettingsStore";
const React = require('react');
const ReactDOM = require("react-dom");
const TestUtils = require('react-addons-test-utils');
@ -23,7 +25,6 @@ import sinon from 'sinon';
const sdk = require('matrix-react-sdk');
const MessagePanel = sdk.getComponent('structures.MessagePanel');
import UserSettingsStore from '../../../src/UserSettingsStore';
import MatrixClientPeg from '../../../src/MatrixClientPeg';
const test_utils = require('test-utils');
@ -59,7 +60,10 @@ describe('MessagePanel', function() {
sandbox = test_utils.stubClient();
client = MatrixClientPeg.get();
client.credentials = {userId: '@me:here'};
UserSettingsStore.getSyncedSettings = sinon.stub().returns({});
// HACK: We assume all settings want to be disabled
// TODO: {Travis} Run the tests to verify this works
SettingsStore.getValue = sinon.stub().returns(false);
});
afterEach(function() {

View File

@ -6,7 +6,6 @@ import sinon from 'sinon';
import Promise from 'bluebird';
import * as testUtils from '../../../test-utils';
import sdk from 'matrix-react-sdk';
import UserSettingsStore from '../../../../src/UserSettingsStore';
const MessageComposerInput = sdk.getComponent('views.rooms.MessageComposerInput');
import MatrixClientPeg from '../../../../src/MatrixClientPeg';
import RoomMember from 'matrix-js-sdk';