diff --git a/tfjs-core/karma.conf.js b/tfjs-core/karma.conf.js index e9bd0e855d8..6dad6092516 100644 --- a/tfjs-core/karma.conf.js +++ b/tfjs-core/karma.conf.js @@ -55,22 +55,27 @@ const browserstackConfig = { const webworkerConfig = { ...browserstackConfig, files: [ - 'src/setup_test.ts', - 'src/worker_test.ts', + {pattern: 'src/setup_test.ts'}, + {pattern: 'src/worker_test.ts'}, + // Include src files for core, except for the tests + {pattern: 'src/**/!(*_test).ts'}, // Serve dist/tf-core.min.js and tf-backend-cpu.min.js as a static // resource, but do not include in the test runner - {pattern: 'dist/tf-core.min.js', included: false}, - {pattern: 'dist/tf-backend-cpu.min.js', included: false}, + {pattern: 'dist/tf-core.min.js', included: false, served: true}, + {pattern: 'dist/tf-backend-cpu.min.js', included: false, served: true}, + ], + exclude: [ + 'src/tests.ts', + 'src/test_node.ts', + 'src/test_async_backends.ts', ], - exclude: [], - hostname: 'bs-local.com', port: 12345 }; module.exports = function(config) { const args = []; - // If no test environment is set unit tests will run against all registered - // test environments. + // If no test environment is set unit tests will run against all + // registered test environments. if (config.testEnv) { args.push('--testEnv', config.testEnv); } diff --git a/tfjs/scripts/test-ci.sh b/tfjs/scripts/test-ci.sh index 1056341e595..85f5fd0cb50 100755 --- a/tfjs/scripts/test-ci.sh +++ b/tfjs/scripts/test-ci.sh @@ -18,8 +18,8 @@ set -e yarn karma start --browsers='bs_firefox_mac,bs_chrome_mac' --singleRun -cd integration_tests -yarn benchmark-cloud +# cd integration_tests +# yarn benchmark-cloud # Reinstall the following line once https://github.com/tensorflow/tfjs/pull/1663 # is resolved. # yarn benchmark --layers --tfjs-node