aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorCôme Chilliet <come.chilliet@nextcloud.com>2024-01-16 11:30:08 +0100
committerCôme Chilliet <91878298+come-nc@users.noreply.github.com>2024-01-23 17:34:04 +0100
commit10664e952917094f7af15900421f0c0d50b860b8 (patch)
tree2027c146cf1f0998b1b740760ec517a28810c93d /core
parenta09107af7a8a62862ec1e76cf8d518efc18f0d34 (diff)
downloadnextcloud-server-10664e952917094f7af15900421f0c0d50b860b8.tar.gz
nextcloud-server-10664e952917094f7af15900421f0c0d50b860b8.zip
Migrate MySQL utf8mb4 check to new SetupCheck API
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Diffstat (limited to 'core')
-rw-r--r--core/js/setupchecks.js8
-rw-r--r--core/js/tests/specs/setupchecksSpec.js45
2 files changed, 0 insertions, 53 deletions
diff --git a/core/js/setupchecks.js b/core/js/setupchecks.js
index 0be5ceafd36..761fca14ed9 100644
--- a/core/js/setupchecks.js
+++ b/core/js/setupchecks.js
@@ -189,14 +189,6 @@
});
}
- if (data.isMysqlUsedWithoutUTF8MB4) {
- messages.push({
- msg: t('core', 'MySQL is used as database but does not support 4-byte characters. To be able to handle 4-byte characters (like emojis) without issues in filenames or comments for example it is recommended to enable the 4-byte support in MySQL. For further details read {linkstart}the documentation page about this ↗{linkend}.')
- .replace('{linkstart}', '<a target="_blank" rel="noreferrer noopener" class="external" href="' + OC.theme.docPlaceholderUrl.replace('PLACEHOLDER', 'admin-mysql-utf8mb4') + '">')
- .replace('{linkend}', '</a>'),
- type: OC.SetupChecks.MESSAGE_TYPE_WARNING
- })
- }
if (!data.isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed) {
messages.push({
msg: t('core', 'This instance uses an S3 based object store as primary storage. The uploaded files are stored temporarily on the server and thus it is recommended to have 50 GB of free space available in the temp directory of PHP. Check the logs for full details about the path and the available space. To improve this please change the temporary directory in the php.ini or make more space available in that path.'),
diff --git a/core/js/tests/specs/setupchecksSpec.js b/core/js/tests/specs/setupchecksSpec.js
index 68325123efb..ef5ed8fbf4d 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({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyGeneratedURL: 'https://server',
temporaryDirectoryWritable: true,
@@ -261,7 +260,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyGeneratedURL: 'https://server',
temporaryDirectoryWritable: true,
@@ -298,7 +296,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyGeneratedURL: 'https://server',
temporaryDirectoryWritable: true,
@@ -336,7 +333,6 @@ describe('OC.SetupChecks tests', function() {
JSON.stringify({
isFairUseOfFreePushService: true,
reverseProxyDocs: 'https://docs.nextcloud.com/foo/bar.html',
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyGeneratedURL: 'https://server',
temporaryDirectoryWritable: true,
@@ -403,7 +399,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyGeneratedURL: 'https://server',
temporaryDirectoryWritable: true,
@@ -435,41 +430,6 @@ describe('OC.SetupChecks tests', function() {
});
});
- it('should return an error if the php version is no longer supported', function(done) {
- var async = OC.SetupChecks.checkSetup();
-
- suite.server.requests[0].respond(
- 200,
- {
- 'Content-Type': 'application/json',
- },
- JSON.stringify({
- isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: true,
- 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: 'MySQL is used as database but does not support 4-byte characters. To be able to handle 4-byte characters (like emojis) without issues in filenames or comments for example it is recommended to enable the 4-byte support in MySQL. For further details read <a target="_blank" rel="noreferrer noopener" class="external" href="https://docs.example.org/admin-mysql-utf8mb4">the documentation page about this ↗</a>.',
- type: OC.SetupChecks.MESSAGE_TYPE_WARNING
- }]);
- done();
- });
- });
-
// THe following test is invalid as the code in core/js/setupchecks.js is calling
// window.location.protocol which always return http during tests
// if there is a way to trick window.location.protocol during test, then we could re-activate it
@@ -484,7 +444,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyDocs: 'https://docs.nextcloud.com/foo/bar.html',
reverseProxyGeneratedURL: 'http://server',
@@ -520,7 +479,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyDocs: 'https://docs.nextcloud.com/foo/bar.html',
reverseProxyGeneratedURL: 'http://server',
@@ -553,7 +511,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: false,
reverseProxyGeneratedURL: 'https://server',
temporaryDirectoryWritable: true,
@@ -588,7 +545,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyGeneratedURL: 'https://server',
temporaryDirectoryWritable: true,
@@ -630,7 +586,6 @@ describe('OC.SetupChecks tests', function() {
},
JSON.stringify({
isFairUseOfFreePushService: true,
- isMysqlUsedWithoutUTF8MB4: false,
isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed: true,
reverseProxyGeneratedURL: 'https://server',
temporaryDirectoryWritable: false,