多言語化の基盤作り (#55) (#421)

Reviewed-on: #421
Co-authored-by: miteruzo <miteruzo@naver.com>
このコミットはプルリクエスト #421 でマージされました。
このコミットが含まれているのは:
2026-10-03 02:00:09 +09:00
committed by みてるぞ
コミット e6ab941774
91個のファイルの変更、3370行の追加、1223行の削除
+7 -8
ファイルの表示
@@ -898,23 +898,22 @@ RSpec.describe 'Gekanator learning API', type: :request do
describe 'GET /gekanator/questions' do
it 'omits questions for deprecated tags' do
active_tag = Tag.create!(name: 'active_question_tag', category: :general)
deprecated_tag = Tag.create!(
name: 'deprecated_question_tag',
category: :general,
deprecated_at: Time.current
)
active_tag = create(:tag, primary_name: 'active_question_tag', category: :general)
deprecated_tag = create(:tag,
primary_name: 'deprecated_question_tag',
category: :general,
deprecated_at: Time.current)
[active_tag, deprecated_tag].each do |question_tag|
GekanatorQuestion.create!(
text: "#{ question_tag.name }?",
text: "#{ primary_tag_name_for(question_tag, 'ja').name }?",
kind: 'tag',
source: 'admin_curated',
status: 'accepted',
priority_weight: 1.0,
condition: {
type: 'tag',
key: "#{ question_tag.category }:#{ question_tag.name }"
key: "#{ question_tag.category }:#{ primary_tag_name_for(question_tag, 'ja').name }"
},
created_by: admin
)