karma.conf.js 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. module.exports = function(config) {
  2. var configuration = {
  3. frameworks: ['jasmine'],
  4. files: [
  5. 'node_modules/angular/angular.js',
  6. 'node_modules/angular-mocks/angular-mocks.js',
  7. 'node_modules/angular-translate/dist/angular-translate.min.js',
  8. 'node_modules/angular-aria/angular-aria.min.js',
  9. 'node_modules/angular-animate/angular-animate.min.js',
  10. 'node_modules/angular-material/angular-material.min.js',
  11. 'dist/app.js',
  12. 'tests/filters.js',
  13. 'tests/service/message.js',
  14. 'tests/service/mime.js',
  15. 'tests/service/qrcode.js',
  16. 'tests/service/uri.js',
  17. 'tests/service/webclient.js',
  18. 'tests/helpers.js',
  19. ],
  20. customLaunchers: {
  21. Chromium_ci_gitlab: {
  22. base: 'Chromium',
  23. flags: ['--no-sandbox'],
  24. },
  25. Chrome_ci_circle: {
  26. base: 'Chrome',
  27. flags: ['--no-sandbox'],
  28. },
  29. }
  30. };
  31. if (process.env.GITLAB_CI) {
  32. configuration.browsers = ['Chromium_ci_gitlab', 'Firefox'];
  33. } else if (process.env.CIRCLECI) {
  34. configuration.browsers = ['Chrome_ci_circle', 'Firefox'];
  35. } else {
  36. configuration.browsers = ['Chromium', 'Firefox'];
  37. }
  38. config.set(configuration);
  39. }