mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
#60 more fix fot tests
This commit is contained in:
@@ -5,16 +5,16 @@ module.exports = function (config) {
|
||||
|
||||
basePath: '.',
|
||||
|
||||
frameworks: ['jasmine'],
|
||||
frameworks: ['jasmine-ajax', 'jasmine'],
|
||||
|
||||
files: [
|
||||
// paths loaded by Karma
|
||||
{pattern: 'node_modules/angular2/bundles/angular2-polyfills.js', included: true, watched: false},
|
||||
{pattern: 'node_modules/systemjs/dist/system.src.js', included: true, watched: false},
|
||||
{pattern: 'node_modules/rxjs/bundles/Rx.js', included: true, watched: false},
|
||||
{pattern: 'node_modules/angular2/bundles/angular2.dev.js', included: true, watched: false},
|
||||
{pattern: 'node_modules/angular2/bundles/testing.dev.js', included: true, watched: false},
|
||||
{pattern: 'node_modules/angular2/bundles/http.dev.js', included: true, watched: false},
|
||||
{pattern: 'node_modules/angular2/bundles/angular2.dev.js', included: true, served: true, watched: false},
|
||||
{pattern: 'node_modules/angular2/bundles/testing.dev.js', included: true, served: true, watched: false},
|
||||
{pattern: 'node_modules/angular2/bundles/http.dev.js', included: true, served: true, watched: false},
|
||||
{pattern: 'node_modules/angular2/bundles/router.dev.js', included: true, watched: false},
|
||||
{pattern: 'node_modules/alfresco-core-rest-api/bundle.js', included: true, watched: false},
|
||||
{pattern: 'node_modules/ng2-translate/bundles/ng2-translate.js', included: true, watched: false},
|
||||
@@ -53,6 +53,7 @@ module.exports = function (config) {
|
||||
plugins: [
|
||||
'karma-jasmine',
|
||||
'karma-coverage',
|
||||
'karma-jasmine-ajax',
|
||||
'karma-chrome-launcher',
|
||||
'karma-mocha-reporter'
|
||||
],
|
||||
@@ -73,6 +74,8 @@ module.exports = function (config) {
|
||||
{type: 'json', subdir: '.', file: 'coverage-final.json'},
|
||||
{type: 'html'}
|
||||
]
|
||||
}
|
||||
},
|
||||
|
||||
singleRun: false
|
||||
})
|
||||
};
|
||||
|
@@ -1,91 +1,92 @@
|
||||
{
|
||||
"name": "ng2-alfresco-upload",
|
||||
"description": "Alfresco Angular2 Upload Component",
|
||||
"version": "0.1.0",
|
||||
"author": "Alfresco Software, Ltd.",
|
||||
"scripts": {
|
||||
"postinstall": "npm run typings",
|
||||
"typings": "typings install",
|
||||
"start": "npm run test && http-server -c-1 -o -p 8875 .",
|
||||
"build": "npm run tslint && typings install && rm -rf dist && tsc && npm run copytemplates && license-check",
|
||||
"tslint": "npm run tslint-test && npm run tslint-src && npm run tslint-root",
|
||||
"tslint-test": "tslint -c tslint.json test/**/*.ts",
|
||||
"tslint-src": "tslint -c tslint.json src/**/*.ts",
|
||||
"tslint-root": "tslint -c tslint.json *.ts",
|
||||
"copytemplates": "npm run copy-html && npm run copy-css",
|
||||
"copy-html": "copyfiles './src/**/*.html' dist",
|
||||
"copy-css": "copyfiles './src/**/*.css' dist",
|
||||
"licensecheck": "license-check",
|
||||
"tsc": "tsc",
|
||||
"pretest": "npm run build",
|
||||
"test": "karma start karma.conf.js",
|
||||
"posttest": "node_modules/.bin/remap-istanbul -i coverage/coverage-final.json -o coverage -t html",
|
||||
"coverage": "http-server -c-1 -o -p 9875 ./coverage"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/Alfresco/dev-platform-webcomponents.git"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Alfresco/dev-platform-webcomponents/issues"
|
||||
},
|
||||
"license": "Apache-2.0",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "Mario Romano",
|
||||
"email": "mario.romano83@gmail.com"
|
||||
}
|
||||
],
|
||||
"keywords": [
|
||||
"ng2",
|
||||
"angular",
|
||||
"angular2",
|
||||
"alfresco"
|
||||
],
|
||||
"dependencies": {
|
||||
"angular2": "2.0.0-beta.15",
|
||||
"systemjs": "0.19.26",
|
||||
"es6-shim": "^0.35.0",
|
||||
"reflect-metadata": "0.1.2",
|
||||
"rxjs": "5.0.0-beta.2",
|
||||
"ng2-translate": "^1.11.2",
|
||||
"zone.js": "^0.6.12",
|
||||
"es6-module-loader": "^0.17.8"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"angular2": "2.0.0-beta.15"
|
||||
},
|
||||
"devDependencies": {
|
||||
"copyfiles": "^0.2.1",
|
||||
"coveralls": "^2.11.9",
|
||||
"http-server": "0.8.5",
|
||||
"jasmine-ajax": "^3.2.0",
|
||||
"jasmine-core": "2.4.1",
|
||||
"karma": "~0.13.22",
|
||||
"karma-chrome-launcher": "~1.0.1",
|
||||
"karma-coverage": "^1.0.0",
|
||||
"karma-jasmine": "~1.0.2",
|
||||
"karma-mocha-reporter": "^2.0.3",
|
||||
"license-check": "^1.0.4",
|
||||
"remap-istanbul": "^0.6.3",
|
||||
"traceur": "^0.0.91",
|
||||
"tslint": "^3.8.1",
|
||||
"typescript": "^1.8.10",
|
||||
"typings": "^0.7.12"
|
||||
},
|
||||
"license-check-config": {
|
||||
"src": [
|
||||
"**/*.js",
|
||||
"**/*.ts",
|
||||
"!/**/coverage/**/*",
|
||||
"!/**/demo/**/*",
|
||||
"!/**/node_modules/**/*",
|
||||
"!/**/typings/**/*",
|
||||
"!*.js"
|
||||
],
|
||||
"path": "assets/license_header.txt",
|
||||
"blocking": false,
|
||||
"logInfo": false,
|
||||
"logError": true
|
||||
"name": "ng2-alfresco-upload",
|
||||
"description": "Alfresco Angular2 Upload Component",
|
||||
"version": "0.1.0",
|
||||
"author": "Alfresco Software, Ltd.",
|
||||
"scripts": {
|
||||
"postinstall": "npm run typings",
|
||||
"typings": "typings install",
|
||||
"start": "npm run test && http-server -c-1 -o -p 8875 .",
|
||||
"build": "npm run tslint && typings install && rm -rf dist && tsc && npm run copytemplates && license-check",
|
||||
"tslint": "npm run tslint-test && npm run tslint-src && npm run tslint-root",
|
||||
"tslint-test": "tslint -c tslint.json test/**/*.ts",
|
||||
"tslint-src": "tslint -c tslint.json src/**/*.ts",
|
||||
"tslint-root": "tslint -c tslint.json *.ts",
|
||||
"copytemplates": "npm run copy-html && npm run copy-css",
|
||||
"copy-html": "copyfiles './src/**/*.html' dist",
|
||||
"copy-css": "copyfiles './src/**/*.css' dist",
|
||||
"licensecheck": "license-check",
|
||||
"tsc": "tsc",
|
||||
"pretest": "npm run build",
|
||||
"test": "karma start karma.conf.js",
|
||||
"posttest": "node_modules/.bin/remap-istanbul -i coverage/coverage-final.json -o coverage -t html",
|
||||
"coverage": "http-server -c-1 -o -p 9875 ./coverage"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/Alfresco/dev-platform-webcomponents.git"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/Alfresco/dev-platform-webcomponents/issues"
|
||||
},
|
||||
"license": "Apache-2.0",
|
||||
"contributors": [
|
||||
{
|
||||
"name": "Mario Romano",
|
||||
"email": "mario.romano83@gmail.com"
|
||||
}
|
||||
],
|
||||
"keywords": [
|
||||
"ng2",
|
||||
"angular",
|
||||
"angular2",
|
||||
"alfresco"
|
||||
],
|
||||
"dependencies": {
|
||||
"angular2": "2.0.0-beta.15",
|
||||
"systemjs": "0.19.26",
|
||||
"es6-shim": "^0.35.0",
|
||||
"reflect-metadata": "0.1.2",
|
||||
"rxjs": "5.0.0-beta.2",
|
||||
"ng2-translate": "^1.11.2",
|
||||
"zone.js": "^0.6.12",
|
||||
"es6-module-loader": "^0.17.8"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"angular2": "2.0.0-beta.15"
|
||||
},
|
||||
"devDependencies": {
|
||||
"copyfiles": "^0.2.1",
|
||||
"coveralls": "^2.11.9",
|
||||
"http-server": "0.8.5",
|
||||
"jasmine-ajax": "^3.2.0",
|
||||
"jasmine-core": "2.4.1",
|
||||
"karma": "~0.13.22",
|
||||
"karma-chrome-launcher": "~1.0.1",
|
||||
"karma-coverage": "^1.0.0",
|
||||
"karma-jasmine": "~1.0.2",
|
||||
"karma-jasmine-ajax": "^0.1.13",
|
||||
"karma-mocha-reporter": "^2.0.3",
|
||||
"license-check": "^1.0.4",
|
||||
"remap-istanbul": "^0.6.3",
|
||||
"traceur": "^0.0.91",
|
||||
"tslint": "^3.8.1",
|
||||
"typescript": "^1.8.10",
|
||||
"typings": "^0.7.12"
|
||||
},
|
||||
"license-check-config": {
|
||||
"src": [
|
||||
"**/*.js",
|
||||
"**/*.ts",
|
||||
"!/**/coverage/**/*",
|
||||
"!/**/demo/**/*",
|
||||
"!/**/node_modules/**/*",
|
||||
"!/**/typings/**/*",
|
||||
"!*.js"
|
||||
],
|
||||
"path": "assets/license_header.txt",
|
||||
"blocking": false,
|
||||
"logInfo": false,
|
||||
"logError": true
|
||||
}
|
||||
}
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
|
||||
import { it, describe, expect, injectAsync, TestComponentBuilder } from 'angular2/testing';
|
||||
import { FileUploadingDialogComponent } from '../../src/components/file-uploading-dialog.component';
|
||||
import { FileUploadingDialogComponent } from './file-uploading-dialog.component';
|
||||
|
||||
describe('FileUploadDialog', () => {
|
||||
|
||||
|
@@ -19,7 +19,7 @@
|
||||
import { TEST_BROWSER_PLATFORM_PROVIDERS, TEST_BROWSER_APPLICATION_PROVIDERS } from 'angular2/platform/testing/browser';
|
||||
import { it, describe, expect, injectAsync, beforeEachProviders, TestComponentBuilder, setBaseTestProviders } from 'angular2/testing';
|
||||
import { provide } from 'angular2/core';
|
||||
import { UploadButtonComponent } from '../../src/components/upload-button.component';
|
||||
import { UploadButtonComponent } from './upload-button.component';
|
||||
import { TranslateService } from 'ng2-translate/ng2-translate';
|
||||
import { TranslationMock } from '../assets/translation.service.mock';
|
||||
|
||||
|
@@ -16,8 +16,8 @@
|
||||
*/
|
||||
|
||||
import { it, describe, beforeEach, expect } from 'angular2/testing';
|
||||
import { UploadService } from '../../src/services/upload.service';
|
||||
import { FileModel } from '../../src/models/file.model';
|
||||
import { UploadService } from './upload.service';
|
||||
import { FileModel } from './../models/file.model';
|
||||
|
||||
declare let jasmine: any;
|
||||
|
||||
|
Reference in New Issue
Block a user