diff --git a/karma.conf.js b/karma.conf.js index 4040183..c1718c4 100644 --- a/karma.conf.js +++ b/karma.conf.js @@ -1,9 +1,10 @@ // Karma configuration file, see link for more information -// https://karma-runner.github.io/1.0/config/configuration-file.html +// https://karma-runner.github.io/6.4/config/configuration-file.html +// process.env.CHROME_BIN = require('puppeteer').executablePath() module.exports = function (config) { config.set({ - basePath: '.', + basePath: '', logLevel: config.LOG_INFO, frameworks: ['jasmine', '@angular-devkit/build-angular'], plugins: [ @@ -14,18 +15,34 @@ module.exports = function (config) { require('karma-sonarqube-unit-reporter'), require('@angular-devkit/build-angular/plugins/karma') ], + port: 9876, + colors: true, + autoWatch: true, + singleRun: false, + restartOnFileChange: true, + browserConsoleLogOptions: { level: 'debug', format: '%b %T: %m', terminal: true }, + // export CHROME_BIN= + browsers: ['Chrome'], + customLaunchers: { + Chrome: { base: 'ChromeHeadless', flags: ['--no-sandbox', '--disable-web-security'] } + }, client: { - jasmine: { - // you can add configuration options for Jasmine here - // the possible options are listed at https://jasmine.github.io/api/edge/Configuration.html - // for example, you can disable the random execution with `random: false` - // or set a specific seed with `seed: 4321` - random: false - }, + // https://jasmine.github.io/api/edge/Configuration.html + jasmine: { random: false }, clearContext: false // leave Jasmine Spec Runner output visible in browser }, + reporters: ['progress', 'kjhtml', 'coverage', 'sonarqubeUnit'], + preprocessors: { 'src/**/*.js': ['coverage'] }, jasmineHtmlReporter: { - suppressAll: true // removes the duplicated traces + suppressAll: true // remove duplicated traces + }, + sonarqubeReporter: { + basePath: 'src/app', // test files folder + filePattern: '**/*.spec.ts', // test files glob pattern + encoding: 'utf-8', // test files encoding + outputFolder: 'sonar', // report destination + legacyMode: false, // report for Sonarqube < 6.2 (disabled) + reportName: 'sonarqube_report.xml' }, sonarQubeUnitReporter: { sonarQubeVersion: 'LATEST', @@ -39,20 +56,6 @@ module.exports = function (config) { dir: 'reports', subdir: 'coverage', // common name instaed browser-specific reporters: [{ type: 'text-summary' }, { type: 'lcov' }] - }, - reporters: ['progress', 'kjhtml', 'coverage', 'sonarqubeUnit'], - preprocessors: { 'src/**/*.js': ['coverage'] }, - port: 9876, - colors: true, - autoWatch: true, - singleRun: false, - restartOnFileChange: true, - browsers: ['HeadlessChrome'], - customLaunchers: { - HeadlessChrome: { - base: 'ChromeHeadless', - flags: ['--no-sandbox'] - } } }) } diff --git a/src/app/permission/app-detail/app-detail.component.html b/src/app/permission/app-detail/app-detail.component.html index fcb2a31..03ce3e3 100644 --- a/src/app/permission/app-detail/app-detail.component.html +++ b/src/app/permission/app-detail/app-detail.component.html @@ -21,11 +21,12 @@ *ngIf="!loadingExceptionKey" #permissionTable id="apm_app_detail_permission_table" - styleClass="px-3" - [columns]="roles" + styleClass="px-3 p-datatable-striped" + [columns]="rolesFiltered" [value]="permissionRows" [globalFilterFields]="filterBy" [scrollable]="true" + scrollHeight="590px" [paginator]="true" [alwaysShowPaginator]="true" [rows]="10" @@ -132,25 +133,32 @@ - + -
-
- {{ 'PERMISSION.LABEL' | translate }} +
+
+ {{ 'PERMISSION.LABEL' | translate }} - + + + +
- -
- {{ 'ROLE.LABEL' | translate }} - - - -
- +
+ + + + + + +
+
+ + +
- + {{ 'PERMISSION.ACTIONS' | translate }} - +