Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-9433

Add test/cppsuite to s_string

    • 2
    • 2023-04-04 Bibbidi-Bobbidi-Boo

      Update: This ticket originally required updates to aspell in order to run s_string on the cppsuite code, but since then we've defined our cpp style guide which uses snake_case and this update is no longer required. The scope of this ticket is now only to enable s_string on cppsuite.

      Summary
      WT-9385 updates cppsuite code to use camelCase for function names as per the mongo C++ style guide. However, while s_string was able to understand that snake_case (pad_string()) names are comprised of two correct words, it doesn't understand this for the new camelCase (padString()) names and reports false errors.

      This is because s_string calls the spellchecking program aspell, but the version available on our platforms (aspell 0.60.7-20110707) doesn't support camel case. Newer versions of aspell, as of version 0.60.8, support this via the --camel-case flag.

      For now we have disabled s_string on the cppsuite code, but this needs fixing. To do so we need to update the available version of aspell across all platforms running s_all.

      Additionally during investigation we found that s_spell is not being applied to the C++ code in ext/storage_sources/s3_store. We should review the list of files s_string is applied to and make sure we are covering all of our source files.

       

      Motivation

      • Does this affect any team outside of WT?
        No
      • How likely is it that this use case or problem will occur?
        N/A
      • If the problem does occur, what are the consequences and how severe are they?
        None. This just prevents spell checking on C++ code.
      • Is this issue urgent?
        No

      Acceptance Criteria (Definition of Done)
      s_string can be applied to C++ code using camel case function names. It doesn't report false positives such as padString, and does report errors such as paddString.
      s_string is also being applied to the S3 code in ext/storage_sources/s3_store.

            Assignee:
            andrew.morton@mongodb.com Andrew Morton
            Reporter:
            andrew.morton@mongodb.com Andrew Morton
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: