question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

6.1.3 Regression with selectors

See original GitHub issue

After upgrading to the latest shallow render, my tests started failing. Before, I was at 6.0.6.

Here is the error:

	Unexpected closing tag "__MockOfEmptyOutletComponent-selector". It may happen when the tag has already been closed by another tag. For more info see https://www.w3.org/TR/html5/syntax.html#closing-elements-that-have-implied-end-tags ("<__MockOfEmptyOutletComponent-selector>[ERROR ->]</__MockOfEmptyOutletComponent-selector>"): @0:39
	    at syntaxError (./node_modules/@angular/compiler/fesm5/compiler.js?:1275:17)
	    at TemplateParser.parse (./node_modules/@angular/compiler/fesm5/compiler.js?:15084:19)
	    at JitCompiler._parseTemplate (./node_modules/@angular/compiler/fesm5/compiler.js?:24272:37)
	    at JitCompiler._compileTemplate (./node_modules/@angular/compiler/fesm5/compiler.js?:24259:23)
	    at eval (./node_modules/@angular/compiler/fesm5/compiler.js?:24202:62)
	    at Set.forEach (<anonymous>)
	    at JitCompiler._compileComponents (./node_modules/@angular/compiler/fesm5/compiler.js?:24202:19)
	    at eval (./node_modules/@angular/compiler/fesm5/compiler.js?:24120:19)
	    at Object.then (./node_modules/@angular/compiler/fesm5/compiler.js?:1266:77)

Downgrading to 6.1.2 solves the issue.

Commit that seemed to cause it: https://github.com/getsaf/shallow-render/commit/07ac3a3553ae174b27c82caf4dd38e43e91f6543

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:1
  • Comments:10 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
PaulDLWcommented, Nov 2, 2018

Would echo @kylecannon sentiment. Absolutely love using shallow, but it is a pain to export the routingModuleRef in lots of different places and update multiple tests to use it.

1reaction
getsafcommented, Dec 5, 2018

@villelahdenvuo, @kylecannon I dug into what happens when the RouterModule was being created and noticed that when using RouterModule.forRoot() it simply creates a ModuleWithProviders where the ngModule is RouterModule. The matching on shallow.replaceModule was very strict and wouldn’t match the ModuleWithReplacements to the RouterModule but I can’t think of any good reason NOT to treat this as a match.

I just made a PR for this fix (#77) and I will release a minor 7.1.0 since it could potentially break some folks under certain strange circumstances.

Read more comments on GitHub >

github_iconTop Results From Across the Web

6.1. Pipelines and composite estimators - Scikit-learn
Transformers are usually combined with classifiers, regressors or other estimators to build a composite estimator. The most common tool is a Pipeline.
Read more >
Chapter 17 Regression | Introduction to Data Science - rafalab
This book introduces concepts and skills that can help you tackle real-world data analysis challenges. It covers concepts from probability, ...
Read more >
6.1 Multivariate linear regression | Fisheries Catch Forecasting
This book will show you how to model and forecast annual and seasonal fisheries catches using R and its time-series analysis functions and...
Read more >
6.2 Kernel regression estimation | Notes for Predictive Modeling
6.2.1 Nadaraya–Watson estimator. Our objective is to estimate the regression function m:Rp→R m : R p → R nonparametrically (recall that we are...
Read more >
Simultaneous Analysis of LASSO and Datnzig Selector
LASSO and Dantzig Selector Definitions (Section 2). 2. Restricted Positive Definiteness (Section 3). 3. Linear Regression Model (Section 7).
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found