mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-10 23:45:44 +01:00
correct structure of config state part
This commit is contained in:
@@ -100,7 +100,7 @@ describe("config reducer", () => {
|
||||
it("should update state correctly according to FETCH_CONFIG_SUCCESS action", () => {
|
||||
const newState = reducer({}, fetchConfigSuccess(config));
|
||||
|
||||
expect(newState.config).toEqual({
|
||||
expect(newState).toEqual({
|
||||
entries: config,
|
||||
configUpdatePermission: true
|
||||
});
|
||||
@@ -109,12 +109,12 @@ describe("config reducer", () => {
|
||||
it("should set configUpdatePermission to true if update link is present", () => {
|
||||
const newState = reducer({}, fetchConfigSuccess(config));
|
||||
|
||||
expect(newState.config.configUpdatePermission).toBeTruthy();
|
||||
expect(newState.configUpdatePermission).toBeTruthy();
|
||||
});
|
||||
|
||||
it("should update state according to FETCH_GROUP_SUCCESS action", () => {
|
||||
it("should update state according to FETCH_CONFIG_SUCCESS action", () => {
|
||||
const newState = reducer({}, fetchConfigSuccess(config));
|
||||
expect(newState.config.entries).toBe(config);
|
||||
expect(newState.entries).toBe(config);
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user