diff --git a/composer.json b/composer.json
index 66d7ed660f..48e373d3c2 100644
--- a/composer.json
+++ b/composer.json
@@ -73,22 +73,22 @@
}
},
"replace": {
- "baserproject/baser-core": "5.0.5",
- "baserproject/bc-admin-third": "5.0.5",
- "baserproject/bc-blog": "5.0.5",
- "baserproject/bc-column": "5.0.5",
- "baserproject/bc-content-link": "5.0.5",
- "baserproject/bc-custom-content": "5.0.5",
- "baserproject/bc-editor-template": "5.0.5",
- "baserproject/bc-favorite": "5.0.5",
- "baserproject/bc-front": "5.0.5",
- "baserproject/bc-installer": "5.0.5",
- "baserproject/bc-mail": "5.0.5",
- "baserproject/bc-search-index": "5.0.5",
- "baserproject/bc-theme-config": "5.0.5",
- "baserproject/bc-theme-file": "5.0.5",
- "baserproject/bc-uploader": "5.0.5",
- "baserproject/bc-widget-area": "5.0.5"
+ "baserproject/baser-core": "5.0.6",
+ "baserproject/bc-admin-third": "5.0.6",
+ "baserproject/bc-blog": "5.0.6",
+ "baserproject/bc-column": "5.0.6",
+ "baserproject/bc-content-link": "5.0.6",
+ "baserproject/bc-custom-content": "5.0.6",
+ "baserproject/bc-editor-template": "5.0.6",
+ "baserproject/bc-favorite": "5.0.6",
+ "baserproject/bc-front": "5.0.6",
+ "baserproject/bc-installer": "5.0.6",
+ "baserproject/bc-mail": "5.0.6",
+ "baserproject/bc-search-index": "5.0.6",
+ "baserproject/bc-theme-config": "5.0.6",
+ "baserproject/bc-theme-file": "5.0.6",
+ "baserproject/bc-uploader": "5.0.6",
+ "baserproject/bc-widget-area": "5.0.6"
},
"scripts": {
"post-install-cmd": "App\\Console\\Installer::postInstall",
diff --git a/phpunit.xml.dist b/phpunit.xml.dist
index 9f4c4005b1..0bff8adc2e 100644
--- a/phpunit.xml.dist
+++ b/phpunit.xml.dist
@@ -36,9 +36,9 @@
plugins/bc-search-index/tests/TestCase
-
-
-
+
+ plugins/bc-theme-config/tests/TestCase
+
diff --git a/plugins/baser-core/VERSION.txt b/plugins/baser-core/VERSION.txt
index 15a0980976..00a8ee1abe 100644
--- a/plugins/baser-core/VERSION.txt
+++ b/plugins/baser-core/VERSION.txt
@@ -1,4 +1,4 @@
-5.0.5
+5.0.7-dev
///////////////////////////////////////////////////////////////////////////////////////////////////////////
// +---------------------------------------------------------------------------------------------------+ //
@@ -14,6 +14,13 @@
CHG: 変更内容 / BUG: バグフィックス / NEW: 機能追加
+[2023-10-26] basercms-5.0.6
+- BUG [BC] fix #1903 コンテンツ一覧(表)コピーの際にコピー先のタイトルに「のコピー」とつかない問題の改善
+- BUG [BC] fix #2783 CGIモードでJWT認証が可能なよう改善
+- BUG [BC] fix #2403 アップロードファイルのAPIにフルパスのURLを追加
+- BUG [ML] fix #1901 バリデーションエラー時にチェックボックスのチェックが外れる
+- BUG [ML] fix #2806 メールプラグインが有効化されていない場合にダッシュボードが表示できない問題の改善
+
[2023-09-28] basercms-5.0.5
- BUG [BC] fix #2744 カスタムコンテンツのバリデーションエラーを改善
- BUG [BC] fix #2199 カスタムコンテンツのAPIで取得する情報に不要な連携データが含まれる処理の改善
diff --git a/plugins/bc-theme-config/tests/TestCase/Controller/Admin/ThemeConfigsControllerTest.php b/plugins/bc-theme-config/tests/TestCase/Controller/Admin/ThemeConfigsControllerTest.php
index 1d47a42dbd..10536fbf82 100644
--- a/plugins/bc-theme-config/tests/TestCase/Controller/Admin/ThemeConfigsControllerTest.php
+++ b/plugins/bc-theme-config/tests/TestCase/Controller/Admin/ThemeConfigsControllerTest.php
@@ -14,12 +14,12 @@
use BaserCore\TestSuite\BcTestCase;
use BaserCore\Utility\BcContainerTrait;
use BcThemeConfig\Controller\Admin\ThemeConfigsController;
+use BcThemeConfig\Test\Scenario\ThemeConfigsScenario;
use CakephpFixtureFactories\Scenario\ScenarioAwareTrait;
/**
* Class ThemeConfigsControllerTest
*
- * @property ThemeConfigsController $ThemeConfigsController
*/
class ThemeConfigsControllerTest extends BcTestCase
{
@@ -29,6 +29,12 @@ class ThemeConfigsControllerTest extends BcTestCase
use ScenarioAwareTrait;
use BcContainerTrait;
+ /**
+ * ThemeConfigsController
+ * @var ThemeConfigsController
+ */
+ public $ThemeConfigsController;
+
/**
* set up
*
@@ -37,6 +43,10 @@ class ThemeConfigsControllerTest extends BcTestCase
public function setUp(): void
{
parent::setUp();
+ $this->loadFixtureScenario(InitAppScenario::class);
+ $request = $this->getRequest('/baser/admin/bc-custom-content/custom_entries/');
+ $request = $this->loginAdmin($request);
+ $this->ThemeConfigsController = new ThemeConfigsController($request);
}
/**
@@ -57,20 +67,18 @@ public function testIndex()
//準備
$this->enableSecurityToken();
$this->enableCsrfToken();
- $this->loadFixtureScenario(InitAppScenario::class);
+ $this->loadFixtureScenario(ThemeConfigsScenario::class);
$data = [
'name_add' => 'value_edit'
];
$this->post("/baser/admin/bc-theme-config/theme_configs/index", $data);
//ステータスを確認
$this->assertResponseSuccess();
- $var = $this->_controller->viewBuilder()->getVars();
- $this->assertArrayHasKey('themeConfig', $var);
- $this->assertEquals('value_edit', $var['themeConfig']->name_add);
+ $this->assertFlashMessage('テーマ設定を保存しました。');
$this->assertRedirect([
'plugin' => 'BcThemeConfig',
'prefix' => 'Admin',
- 'controller' => 'ThemeConfigsController',
+ 'controller' => 'ThemeConfigs',
'action' => 'index'
]);
}
diff --git a/plugins/bc-theme-config/tests/TestCase/Controller/Api/Admin/ThemeConfigsControllerTest.php b/plugins/bc-theme-config/tests/TestCase/Controller/Api/Admin/ThemeConfigsControllerTest.php
index 84dc0a7fa3..769487e8d3 100644
--- a/plugins/bc-theme-config/tests/TestCase/Controller/Api/Admin/ThemeConfigsControllerTest.php
+++ b/plugins/bc-theme-config/tests/TestCase/Controller/Api/Admin/ThemeConfigsControllerTest.php
@@ -76,7 +76,7 @@ public function test_view()
//戻る値を確認
$result = json_decode((string)$this->_response->getBody());
//全て4件を取得できるか確認
- $this->assertCount(4, get_object_vars($result->themeConfig));
+ $this->assertCount(5, get_object_vars($result->themeConfig));
//単位Objectの値を確認
$this->assertEquals('2B7BB9', $result->themeConfig->color_hover);
}
diff --git a/plugins/bc-theme-config/tests/TestCase/Service/ThemeConfigsServiceTest.php b/plugins/bc-theme-config/tests/TestCase/Service/ThemeConfigsServiceTest.php
index 65d5933a58..08adb43c5c 100644
--- a/plugins/bc-theme-config/tests/TestCase/Service/ThemeConfigsServiceTest.php
+++ b/plugins/bc-theme-config/tests/TestCase/Service/ThemeConfigsServiceTest.php
@@ -132,11 +132,6 @@ public function test_saveImage()
$logoPath = '/var/www/html/plugins/bc-column/webroot/img/logo.png';
$this->setUploadFileToRequest('file', $logoPath);
- // saveImage の内部で実行される move_uploaded_file() が、
- // 実際にファイルをアップロードしないと失敗してしまうため、copy() で代替処理とする
- $uploadedPath = WWW_ROOT . 'files' . DS . 'theme_configs' . DS. 'logo.png';
- copy($logoPath, $uploadedPath);
-
// 実行
$rs = $this->ThemeConfigsService->saveImage(new ThemeConfig([
'logo' => [
@@ -147,16 +142,18 @@ public function test_saveImage()
'size' => 2962,
]
]));
+ // saveImage の内部で実行される move_uploaded_file() が、
+ // 実際にファイルをアップロードしないと失敗してしまうため、copy() で代替処理とする
+ $uploadedPath = WWW_ROOT . 'files' . DS . 'theme_configs' . DS. 'logo.png';
+ copy($logoPath, $uploadedPath);
// 戻り値を確認
$this->assertEquals($rs['logo'], 'logo.png');
// サムネイルが作成されたことを確認
- $thumbPath = WWW_ROOT . 'files' . DS . 'theme_configs' . DS. 'logo_thumb.png';
- $this->assertFileExists($thumbPath);
+ $this->assertFileExists($uploadedPath);
// 初期化処理
unlink($uploadedPath);
- unlink($thumbPath);
}
/**