Skip to content

機関ストレージ (S3CompatSigV4) のファイルプロパティ期待値を修正#33

Merged
yacchin1205 merged 1 commit intoRCOSDP:mainfrom
yacchin1205:fix/s3compatsigv4-info
Apr 18, 2026
Merged

機関ストレージ (S3CompatSigV4) のファイルプロパティ期待値を修正#33
yacchin1205 merged 1 commit intoRCOSDP:mainfrom
yacchin1205:fix/s3compatsigv4-info

Conversation

@yacchin1205
Copy link
Copy Markdown
Collaborator

@yacchin1205 yacchin1205 commented Apr 17, 2026

Purpose

admin-minio CI(機関ストレージ S3CompatSigV4 配下の「ファイル基本操作」テスト)で、ファイルプロパティの「作成日時」検証が失敗していた。これを修正する。

https://github.com/RCOSDP/RDM-e2e-test-nb/actions/runs/24564925651/job/71822555036

result-20260417-124612/テスト手順-管理者機能-S3CompatSigV4-機関ストレージ/notebooks/テスト手順-ストレージ共通-ファイル基本操作-file-tab.ipynb:
  - Cell 106: AssertionError: Locator expected to be empty
Actual value: notEmpty 
Call log:
  - Expect "to_be_empty" with timeout 5000ms
  - waiting for locator("//*[@id = \"tb-tbody\"]//*[@class = \"modal-content\"]//*[text() = \"作成日時: \"]/following-sibling::span")
    9 × locator resolved to <span>2026-04-17 01:06:17 PM</span>
      - unexpected value "notEmpty"


result-20260417-124612/テスト手順-管理者機能-S3CompatSigV4-機関ストレージ/notebooks/テスト手順-ストレージ共通-ファイル基本操作.ipynb:
  - Cell 106: AssertionError: Locator expected to be empty
Actual value: notEmpty 
Call log:
  - Expect "to_be_empty" with timeout 5000ms
  - waiting for locator("//*[@id = \"tb-tbody\"]//*[@class = \"modal-content\"]//*[text() = \"作成日時: \"]/following-sibling::span")
    9 × locator resolved to <span>2026-04-17 01:04:20 PM</span>
      - unexpected value "notEmpty"

機関ストレージは WaterButler レベルでは osfstorage として動作する(管理者画面で機関に S3CompatSigV4 を割り当てても、プロジェクトからのアクセスは osfstorage プロバイダ経由)。そのため、ファイル/フォルダプロパティダイアログの作成日時/更新日時/最終更新者は osfstorage と同じく非空で表示されるのが正しい仕様。テスト側の期待値が「S3互換 = 作成日時=空」と決め打ちしていたため失敗していた。

併せて行うリファクタ

バグ修正にあたり、scripts/grdm.py 内のユーティリティ関数 display_property_*_info が provider 種別ごとの期待値分岐を内部に持っていたことが、今回の取り違え(機関ストレージの表示名 'S3CompatSigV4 Storage' が暗黙の else 分岐に吸われた)の構造的原因だった。

そのため、以下の責務分離を併せて行う:

  • scripts/grdm.py のユーティリティ関数は期待値の決定責務を負わない。操作と検証のみを担い、期待値は呼び出し元から引数で受け取る。
  • 期待値はテスト手順 Notebook 側で定義する。新ストレージや新しい利用形態が増えた場合もユーティリティ関数を変更せず、Notebook 側で対応する。

Changes

  • scripts/grdm.py: display_property_*_info を削除し、期待値を引数で受け取る verify_property_*_info を追加(プロバイダ分岐ロジックなし)
  • テスト手順-ストレージ共通-ファイル基本操作.ipynb: パラメータに target_storage_id を追加、冒頭に「プロパティダイアログの期待値決定」セルを挿入、各検証ステップを新関数の呼び出しに変更し、Markdown セルに期待結果を追記
  • 取りまとめ Notebook 4 つ (取りまとめ-NIIストレージ, 取りまとめ-S3共通, 取りまとめ-S3CompatSigV4, 取りまとめ-拡張ストレージ-共通試験): テスト手順-ストレージ共通-ファイル基本操作.ipynb 呼び出し時に target_storage_id を伝搬
  • テスト手順-管理者機能-S3CompatSigV4-機関ストレージ.ipynb: 機関ストレージは実質 osfstorage として動作するため target_storage_id='osfstorage' を渡す

Ticket

n/a

Custom Test Configuration

  • RDM_REPOSITORY:
  • RDM_BRANCH:
  • EMBER_IMAGE:
  • EXCLUDE_NOTEBOOKS:

@yacchin1205 yacchin1205 changed the title ファイル基本操作テスト: プロパティ期待値を target_storage_id で決定 機関ストレージ (S3CompatSigV4) のファイルプロパティ期待値を修正 Apr 18, 2026
@yacchin1205 yacchin1205 merged commit cca6846 into RCOSDP:main Apr 18, 2026
13 of 16 checks passed
yacchin1205 added a commit that referenced this pull request Apr 18, 2026
機関ストレージ (S3CompatSigV4) のファイルプロパティ期待値を修正
@yacchin1205 yacchin1205 deleted the fix/s3compatsigv4-info branch April 19, 2026 01:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant