- Created a comprehensive user testing plan document to validate the app's usability, reliability, accessibility, and resilience. - Included various test scenarios covering onboarding, product scanning, manual barcode entry, and accessibility features. chore: update dependencies for code quality tools - Added ktlint version 12.2.0 for Kotlin code style enforcement. - Added detekt version 1.23.7 for static code analysis. chore: increment version numbers - Updated MINOR version to 32 and CODE to 43 in version.properties to reflect recent changes.
112 lines
2.7 KiB
YAML
112 lines
2.7 KiB
YAML
# Detekt configuration — SafeBite
|
|
# https://detekt.dev/docs/rules/overview
|
|
|
|
build:
|
|
maxIssues: 0
|
|
excludeCorrectable: true
|
|
weights:
|
|
complexity: 2
|
|
formatting: 1
|
|
long-parameter-list: 1
|
|
comments: 1
|
|
|
|
config:
|
|
validation: true
|
|
warningsAsErrors: false
|
|
|
|
style:
|
|
active: true
|
|
MagicNumber:
|
|
active: true
|
|
excludes: ['**/test/**', '**/androidTest/**', '**/Color.kt', '**/Dimens.kt', '**/Theme.kt', '**/StatusColors.kt', '**/Converters.kt', '**/migration/**']
|
|
ignoreNumbers: ['-1', '0', '1', '2', '100', '1000']
|
|
MaxLineLength:
|
|
active: true
|
|
maxLineLength: 160
|
|
excludes: ['**/test/**', '**/androidTest/**', '**/CategoryEngine.kt', '**/ListSortScreen.kt']
|
|
WildcardImport:
|
|
active: false
|
|
ForbiddenComment:
|
|
active: false
|
|
UnusedPrivateMember:
|
|
active: true
|
|
UnusedImports:
|
|
active: true
|
|
DestructuringDeclarationWithTooManyEntries:
|
|
active: false
|
|
ReturnCount:
|
|
active: true
|
|
max: 3
|
|
|
|
complexity:
|
|
active: true
|
|
LongParameterList:
|
|
active: true
|
|
functionThreshold: 10
|
|
constructorThreshold: 12
|
|
ignoreDefaultParameters: true
|
|
TooManyFunctions:
|
|
active: true
|
|
excludes: ['**/test/**', '**/androidTest/**', '**/Screen.kt', '**/ViewModel.kt', '**/Dao.kt', '**/Repository.kt', '**/Repositories.kt', '**/Engine.kt', '**/Provider.kt']
|
|
thresholdInFiles: 25
|
|
thresholdInClasses: 20
|
|
thresholdInInterfaces: 25
|
|
thresholdInObjects: 20
|
|
LargeClass:
|
|
active: true
|
|
excludes: ['**/test/**', '**/androidTest/**', '**/Screen.kt', '**/ViewModel.kt', '**/CatalogProvider.kt']
|
|
threshold: 800
|
|
LongMethod:
|
|
active: true
|
|
excludes: ['**/test/**', '**/androidTest/**', '**/Screen.kt', '**/NavGraph.kt']
|
|
threshold: 120
|
|
CyclomaticComplexMethod:
|
|
active: true
|
|
excludes: ['**/test/**', '**/androidTest/**', '**/HealthClassifier.kt']
|
|
threshold: 20
|
|
NestedBlockDepth:
|
|
active: false
|
|
|
|
naming:
|
|
active: true
|
|
ClassNaming:
|
|
active: true
|
|
FunctionNaming:
|
|
active: false # @Composable functions use PascalCase
|
|
TopLevelPropertyNaming:
|
|
active: true
|
|
constantPattern: '[A-Z][A-Za-z0-9]*'
|
|
MatchingDeclarationName:
|
|
active: false # Multi-declaration files allowed
|
|
|
|
coroutines:
|
|
active: true
|
|
|
|
exceptions:
|
|
active: true
|
|
TooGenericExceptionCaught:
|
|
active: true
|
|
excludes: ['**/test/**', '**/androidTest/**', '**/ScannerScreen.kt', '**/ProductRepositoryImpl.kt']
|
|
SwallowedException:
|
|
active: true
|
|
ignoredExceptionTypes:
|
|
- 'kotlin.Throwable'
|
|
|
|
empty-blocks:
|
|
active: true
|
|
|
|
comments:
|
|
active: true
|
|
CommentOverPrivateFunction:
|
|
active: false
|
|
CommentOverPrivateProperty:
|
|
active: false
|
|
|
|
performance:
|
|
ForEachOnRange:
|
|
active: false
|
|
|
|
potential-bugs:
|
|
ImplicitDefaultLocale:
|
|
active: false # FR-only app, no locale issue
|