aboutsummaryrefslogtreecommitdiffstats
path: root/core/js
diff options
context:
space:
mode:
authorCôme Chilliet <come.chilliet@nextcloud.com>2023-10-26 14:45:05 +0200
committerCôme Chilliet <come.chilliet@nextcloud.com>2023-11-07 12:14:02 +0100
commit5957a2bf6bfbb89c7c6b689e3eef89b7072fe3cf (patch)
treedf20b4279431ea0c612d664572322083637e4d8e /core/js
parent506f3961ecf6616bac81f2c56d5e20d58ab435c6 (diff)
downloadnextcloud-server-5957a2bf6bfbb89c7c6b689e3eef89b7072fe3cf.tar.gz
nextcloud-server-5957a2bf6bfbb89c7c6b689e3eef89b7072fe3cf.zip
Migrate email test to new SetupCheck API
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Diffstat (limited to 'core/js')
-rw-r--r--core/js/setupchecks.js8
-rw-r--r--core/js/tests/specs/setupchecksSpec.js87
2 files changed, 0 insertions, 95 deletions
diff --git a/core/js/setupchecks.js b/core/js/setupchecks.js
index e94c334db66..04eed184c90 100644
--- a/core/js/setupchecks.js
+++ b/core/js/setupchecks.js
@@ -180,14 +180,6 @@
var afterCall = function(data, statusText, xhr) {
var messages = [];
if (xhr.status === 200 && data) {
- if (!data.wasEmailTestSuccessful) {
- messages.push({
- msg: t('core', 'You have not set or verified your email server configuration, yet. Please head over to the {mailSettingsStart}Basic settings{mailSettingsEnd} in order to set them. Afterwards, use the "Send email" button below the form to verify your settings.',)
- .replace('{mailSettingsStart}', '<a href="' + OC.generateUrl('/settings/admin') + '">')
- .replace('{mailSettingsEnd}', '</a>'),
- type: OC.SetupChecks.MESSAGE_TYPE_INFO
- });
- }
if (!data.hasValidTransactionIsolationLevel) {
messages.push({
msg: t('core', 'Your database does not run with "READ COMMITTED" transaction isolation level. This can cause problems when multiple actions are executed in parallel.'),
diff --git a/core/js/tests/specs/setupchecksSpec.js b/core/js/tests/specs/setupchecksSpec.js
index 982cb254daa..14f8d95e962 100644
--- a/core/js/tests/specs/setupchecksSpec.js
+++ b/core/js/tests/specs/setupchecksSpec.js
@@ -224,7 +224,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -292,7 +291,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -360,7 +358,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -424,7 +421,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -487,7 +483,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -540,69 +535,6 @@ describe('OC.SetupChecks tests', function() {
});
});
- it('should return an info if the mail server config was not set or verified, yet', function(done) {
- var async = OC.SetupChecks.checkSetup();
-
- suite.server.requests[0].respond(
- 200,
- {
- 'Content-Type': 'application/json'
- },
- JSON.stringify({
- hasFileinfoInstalled: true,
- wasEmailTestSuccessful: false,
- hasWorkingFileLocking: true,
- hasDBFileLocking: false,
- hasValidTransactionIsolationLevel: true,
- suggestedOverwriteCliURL: '',
- isRandomnessSecure: true,
- securityDocs: 'https://docs.nextcloud.com/myDocs.html',
- isFairUseOfFreePushService: true,
- isMemcacheConfigured: true,
- forwardedForHeadersWorking: true,
- isCorrectMemcachedPHPModuleInstalled: true,
- hasPassedCodeIntegrityCheck: true,
- OpcacheSetupRecommendations: [],
- isSettimelimitAvailable: true,
- hasFreeTypeSupport: true,
- missingIndexes: [],
- missingPrimaryKeys: [],
- missingColumns: [],
- cronErrors: [],
- cronInfo: {
- diffInSeconds: 0
- },
- isMemoryLimitSufficient: true,
- appDirsWithDifferentOwner: [],
- isImagickEnabled: true,
- areWebauthnExtensionsEnabled: true,
- is64bit: true,
- pendingBigIntConversionColumns: [],
- isMysqlUsedWithoutUTF8MB4: false,
- isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
- reverseProxyGeneratedURL: 'https://server',
- temporaryDirectoryWritable: true,
- generic: {
- network: {
- "Internet connectivity": {
- severity: "success",
- description: null,
- linkToDoc: null
- }
- },
- },
- })
- );
-
- async.done(function( data, s, x ){
- expect(data).toEqual([{
- msg: 'You have not set or verified your email server configuration, yet. Please head over to the <a href="http://localhost/index.php/settings/admin">Basic settings</a> in order to set them. Afterwards, use the "Send email" button below the form to verify your settings.',
- type: OC.SetupChecks.MESSAGE_TYPE_INFO
- }]);
- done();
- });
- });
-
it('should return an info if transactional file locking is not set up', function(done) {
var async = OC.SetupChecks.checkSetup();
@@ -613,7 +545,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: false,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -676,7 +607,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: true,
hasValidTransactionIsolationLevel: true,
@@ -739,7 +669,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -804,7 +733,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -867,7 +795,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -932,7 +859,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -995,7 +921,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1078,7 +1003,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1148,7 +1072,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1211,7 +1134,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1274,7 +1196,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1341,7 +1262,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1405,7 +1325,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1466,7 +1385,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1530,7 +1448,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1594,7 +1511,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1657,7 +1573,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1720,7 +1635,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,
@@ -1790,7 +1704,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
hasFileinfoInstalled: true,
- wasEmailTestSuccessful: true,
hasWorkingFileLocking: true,
hasDBFileLocking: false,
hasValidTransactionIsolationLevel: true,