{"action":"created","issue":{"url":"https://api.github.com/repos/ike18t/ng-mocks/issues/31","repository_url":"https://api.github.com/repos/ike18t/ng-mocks","labels_url":"https://api.github.com/repos/ike18t/ng-mocks/issues/31/labels{/name}","comments_url":"https://api.github.com/repos/ike18t/ng-mocks/issues/31/comments","events_url":"https://api.github.com/repos/ike18t/ng-mocks/issues/31/events","html_url":"https://github.com/ike18t/ng-mocks/pull/31","id":383143965,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMyNjg0MDUx","number":31,"title":"Support of latest ngTemplateOutlet API + proper injection of CommonModule to mocked modules","user":{"login":"satanTime","id":966305,"node_id":"MDQ6VXNlcjk2NjMwNQ==","avatar_url":"https://avatars1.githubusercontent.com/u/966305?v=4","gravatar_id":"","url":"https://api.github.com/users/satanTime","html_url":"https://github.com/satanTime","followers_url":"https://api.github.com/users/satanTime/followers","following_url":"https://api.github.com/users/satanTime/following{/other_user}","gists_url":"https://api.github.com/users/satanTime/gists{/gist_id}","starred_url":"https://api.github.com/users/satanTime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/satanTime/subscriptions","organizations_url":"https://api.github.com/users/satanTime/orgs","repos_url":"https://api.github.com/users/satanTime/repos","events_url":"https://api.github.com/users/satanTime/events{/privacy}","received_events_url":"https://api.github.com/users/satanTime/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":13,"created_at":"2018-11-21T14:30:31Z","updated_at":"2018-12-14T07:15:35Z","closed_at":"2018-11-26T16:05:52Z","author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/ike18t/ng-mocks/pulls/31","html_url":"https://github.com/ike18t/ng-mocks/pull/31","diff_url":"https://github.com/ike18t/ng-mocks/pull/31.diff","patch_url":"https://github.com/ike18t/ng-mocks/pull/31.patch"},"body":"Found interesting case: with nested components undefined blocks could cause \"Can't bind to 'ngTemplateOutlet' since it isn't a known property of 'template'\" error - and the problem was cased due to CommonModule wasn't injected properly to mocked module."},"comment":{"url":"https://api.github.com/repos/ike18t/ng-mocks/issues/comments/447237053","html_url":"https://github.com/ike18t/ng-mocks/pull/31#issuecomment-447237053","issue_url":"https://api.github.com/repos/ike18t/ng-mocks/issues/31","id":447237053,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0NzIzNzA1Mw==","user":{"login":"wvankuipers","id":3356735,"node_id":"MDQ6VXNlcjMzNTY3MzU=","avatar_url":"https://avatars1.githubusercontent.com/u/3356735?v=4","gravatar_id":"","url":"https://api.github.com/users/wvankuipers","html_url":"https://github.com/wvankuipers","followers_url":"https://api.github.com/users/wvankuipers/followers","following_url":"https://api.github.com/users/wvankuipers/following{/other_user}","gists_url":"https://api.github.com/users/wvankuipers/gists{/gist_id}","starred_url":"https://api.github.com/users/wvankuipers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wvankuipers/subscriptions","organizations_url":"https://api.github.com/users/wvankuipers/orgs","repos_url":"https://api.github.com/users/wvankuipers/repos","events_url":"https://api.github.com/users/wvankuipers/events{/privacy}","received_events_url":"https://api.github.com/users/wvankuipers/received_events","type":"User","site_admin":false},"created_at":"2018-12-14T07:15:35Z","updated_at":"2018-12-14T07:15:35Z","author_association":"NONE","body":"No problem, here is a (simplified) version of the code:\r\n\r\n```\r\nTestBed.configureTestingModule({\r\n      declarations: [\r\n        RequestAccessComponent,\r\n      ],\r\n      imports: [\r\n        UIModule,\r\n      ],\r\n    });\r\n```\r\n\r\nUIStubModule comes from another (internal) lib, the component that has the ngTemplateOutlet has the following code:\r\n\r\n```\r\n<ng-container *ngIf=\"visible\">\r\n  <ng-container *ngTemplateOutlet=\"modalContent\"></ng-container>\r\n</ng-container>\r\n```\r\n\r\n```\r\nimport {Component, ContentChild, TemplateRef} from '@angular/core';\r\n\r\n@Component({\r\n  selector: 'modal-container',\r\n  templateUrl: 'modal-container.component.html'\r\n})\r\nexport class ModalContainerComponent {\r\n  @ContentChild('modalContent') modalContent: TemplateRef<any>;\r\n}\r\n```\r\n\r\nAnd is then exported via:\r\n\r\n```\r\n@NgModule(  imports: [\r\n    BrowserModule, // exports CommonModule\r\n  ],\r\n  declarations: [ModalContainerComponent],\r\n  exports: [ModalContainerComponent]\r\n)\r\nexport class UIModule {}\r\n```"}}
{"actor":{"display_login":"wvankuipers"}}