Page MenuHomePhabricator

Add tests for Scap cdb generation
Closed, ResolvedPublic

Description

We'll want these tests to pass so we know a Python3 port doesn't break this part of Scap, at least.

Event Timeline

scap/tasks.py has update_l10n_cdb function, which reads JSON files and writes CDB files. I think we need to do the following:

  • extract the actual JSON-to-CDB logic into its own function, without the caching logic
  • find a set of representative JSON files
  • write a test helper using the new function to convert JSON to CDB
  • run the helper with both Python2 and Python3 and check the output is bitwise identical
LarsWirzenius renamed this task from Add tests to Scap cdb generation to Add tests for Scap cdb generation.Jul 14 2020, 2:45 PM
LarsWirzenius lowered the priority of this task from High to Medium.Sep 21 2020, 10:58 AM

Lowering priority as things aren't currently broken.

thcipriani assigned this task to dduvall.
thcipriani subscribed.

There exists a test—maybe 2.