Page MenuHomeSoftware Heritage

hypothesis_strategies: Ensure to generate valid directory entry name
ClosedPublic

Authored by anlambert on Dec 7 2021, 11:32 AM.

Details

Summary

Since rDMOD8d96dfedee34203a4118e48a6208ee507511590b, directory entry names
are validated in DirectoryEntry model and thus must not contain any slash
characters.

So update directory_entries_d hypothesis strategy to ensure such names
are generated to avoid flaky tests.

Spotted yersteday while working on swh-model (see Jenkins builds hstory).

Diff Detail

Repository
rDMOD Data model
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Build is green

Patch application report for D6760 (id=24544)

Rebasing onto 37364c24b5...

Current branch diff-target is up to date.
Changes applied before test
commit 4e2792b8c5386c99e3a5c78d88006ce30cb3f18b
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Tue Dec 7 11:27:49 2021 +0100

    hypothesis_strategies: Ensure to generate valid directory entry name
    
    Since rDMOD8d96dfedee34203a4118e48a6208ee507511590b, directory entry name
    are validated in DirectoryEntry model and thus must not contain any slash
    characters.
    
    So update directory_entries_d hypothesis strategy to ensure such names
    are generated to avoid flaky tests.

See https://jenkins.softwareheritage.org/job/DMOD/job/tests-on-diff/413/ for more details.

Build is green

Patch application report for D6760 (id=24546)

Rebasing onto 37364c24b5...

Current branch diff-target is up to date.
Changes applied before test
commit c525484e473720ffcde89534d3ba89093bc8b016
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Tue Dec 7 11:27:49 2021 +0100

    hypothesis_strategies: Ensure to generate valid directory entry name
    
    Since rDMOD8d96dfedee34203a4118e48a6208ee507511590b, directory entry
    names are validated in DirectoryEntry model and thus must not contain
    any slash characters.
    
    So update directory_entries_d hypothesis strategy to ensure such names
    are generated to avoid flaky tests.

See https://jenkins.softwareheritage.org/job/DMOD/job/tests-on-diff/414/ for more details.

This revision is now accepted and ready to land.Dec 7 2021, 11:39 AM