settings: move ipv6/ipv4 config into network

this also rename sysinfo_config to ipv4_config
This commit is contained in:
Girish Ramakrishnan
2023-08-03 06:05:29 +05:30
parent f2e56cbdd8
commit 92a103d635
14 changed files with 144 additions and 139 deletions
+14
View File
@@ -110,6 +110,20 @@ describe('Network', function () {
});
});
describe('IPv6 config', function () {
it('can get default IPv6 setting', async function () {
const config = await network.getIPv6Config();
expect(config.provider).to.be('noop');
});
it('can set IPv6 setting', async function () {
await network.setIPv6Config({ provider: 'generic' });
const config = await network.getIPv6Config();
expect(config.provider).to.be('generic');
});
});
describe('Dynamic DNS', function () {
it('can get default dyndns', async function () {
expect(await network.getDynamicDns()).to.be(false);
-13
View File
@@ -62,18 +62,6 @@ describe('Settings', function () {
await settings.setBackupPolicy({ schedule: '00 00 2,23 * * 0,1,2', retention: { keepWithinSecs: 1 }});
});
it('can get default IPv6 setting', async function () {
const config = await settings.getIPv6Config();
expect(config.provider).to.be('noop');
});
it('can set IPv6 setting', async function () {
await settings.setIPv6Config({ provider: 'generic' });
const config = await settings.getIPv6Config();
expect(config.provider).to.be('generic');
});
it('can get default profile config', async function () {
const profileConfig = await settings.getProfileConfig();
expect(profileConfig.lockUserProfiles).to.be(false);
@@ -94,6 +82,5 @@ describe('Settings', function () {
const allSettings = await settings.list();
expect(allSettings[settings.TIME_ZONE_KEY]).to.be.a('string');
expect(allSettings[settings.AUTOUPDATE_PATTERN_KEY]).to.be.a('string');
expect(allSettings[settings.IPV6_CONFIG_KEY]).to.be.an('object');
});
});