plotly / plotly/angular-plotly.js

Plotly object not found on window" when unit testing a component

Ouverte
#206 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

Langage dominant
TypeScript
Étoiles
242
Forks
81
Merge moyen
8 h 48 min
PR mergées (30 j)
18

Description

Error: Plotly object not found on window.
Error: Plotly object not found on window. at new PlotlyViaWindowModule (http://localhost:9876/_karma_webpack_/webpack:/node_modules/angular-plotly.js/fesm2015/angular-plotly.js.js:634:1) at Object.PlotlyViaWindowModule_Factory [as factory] (http://localhost:9876/_karma_webpack_/webpack:/node_modules/angular-plotly.js/fesm2015/angular-plotly.js.js:639:74) at R3Injector.hydrate (http://localhost:9876/_karma_webpack_/webpack:/node_modules/@angular/core/fesm2015/core.js:11457:1) at R3Injector.get (http://localhost:9876/_karma_webpack_/webpack:/node_modules/@angular/core/fesm2015/core.js:11276:1) at http://localhost:9876/_karma_webpack_/webpack:/node_modules/@angular/core/fesm2015/core.js:11314:1 at Set.forEach (<anonymous>) at R3Injector._resolveInjectorDefTypes (http://localhost:9876/_karma_webpack_/webpack:/node_modules/@angular/core/fesm2015/core.js:11314:1) at new NgModuleRef$1 (http://localhost:9876/_karma_webpack_/webpack:/node_modules/@angular/core/fesm2015/core.js:25345:1) at R3TestBedCompiler.finalize (http://localhost:9876/_karma_webpack_/webpack:/node_modules/@angular/core/fesm2015/testing.js:926:1) at TestBedRender3.get testModuleRef [as testModuleRef] (http://localhost:9876/_karma_webpack_/webpack:/node_modules/@angular/core/fesm2015/testing.js:1789:1)

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Piste de recherche

Reproduire le test unitaire du composant à l’aide de la trace de pile Karma/Webpack signalée et examiner la configuration d’Angular Plotly autour de PlotlyViaWindowModule. C’est terminé lorsque le test peut s’initialiser sans « Plotly object not found on window » ; l’issue n’indique aucun fichier source ni aucun test du dépôt, il faut donc d’abord les localiser à partir de la spec en échec.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
angular, typescript
Domaine
frontend, testing
Type d'issue
Bug
Difficulté
3/5
Temps estimé
1-2 jours
Activité
À l'abandon
Clarté
À clarifier
Accessibilité débutants
25/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.