feat: adds schematics for service#9945
Conversation
|
@satanTime, can you review this schematic to see if you agree? |
| @@ -0,0 +1,21 @@ | |||
| import { MockBuilder,MockedComponentFixture, MockInstance, MockRender, } from 'ng-mocks'; | |||
|
|
|||
| import { <%= classify(name)%>Service } from './<%= dasherize(name)%>.service'; | |||
Check notice
Code scanning / CodeQL
Syntax error
| @@ -0,0 +1,21 @@ | |||
| import { MockBuilder,MockedComponentFixture, MockInstance, MockRender, } from 'ng-mocks'; | |||
|
|
|||
| import { <%= classify(name)%>Service } from './<%= dasherize(name)%>.service'; | |||
Check notice
Code scanning / CodeQL
Syntax error
| @@ -0,0 +1,21 @@ | |||
| import { MockBuilder,MockedComponentFixture, MockInstance, MockRender, } from 'ng-mocks'; | |||
|
|
|||
| import { <%= classify(name)%>Service } from './<%= dasherize(name)%>.service'; | |||
Check notice
Code scanning / CodeQL
Syntax error
| @@ -0,0 +1,21 @@ | |||
| import { MockBuilder,MockedComponentFixture, MockInstance, MockRender, } from 'ng-mocks'; | |||
|
|
|||
| import { <%= classify(name)%>Service } from './<%= dasherize(name)%>.service'; | |||
Check notice
Code scanning / CodeQL
Syntax error
| @@ -0,0 +1,21 @@ | |||
| import { MockBuilder,MockedComponentFixture, MockInstance, MockRender, } from 'ng-mocks'; | |||
|
|
|||
| import { <%= classify(name)%>Service } from './<%= dasherize(name)%>.service'; | |||
Check notice
Code scanning / CodeQL
Syntax error
|
|
||
| describe('<%= classify(name)%>Service', () => { | ||
| let service: <%= classify(name)%>Service; | ||
| let fixture: MockedComponentFixture<<%= classify(name)%>Service>; |
Check notice
Code scanning / CodeQL
Syntax error
|
|
||
| MockInstance.scope(); | ||
|
|
||
| beforeEach(() => MockBuilder(<%= classify(name)%>Service)); |
Check notice
Code scanning / CodeQL
Syntax error
|
|
||
| MockInstance.scope(); | ||
|
|
||
| beforeEach(() => MockBuilder(<%= classify(name)%>Service)); |
Check notice
Code scanning / CodeQL
Syntax error
| beforeEach(() => MockBuilder(<%= classify(name)%>Service)); | ||
|
|
||
| beforeEach(() => { | ||
| fixture = MockRender(<%= classify(name)%>Service); |
Check notice
Code scanning / CodeQL
Syntax error
| beforeEach(() => MockBuilder(<%= classify(name)%>Service)); | ||
|
|
||
| beforeEach(() => { | ||
| fixture = MockRender(<%= classify(name)%>Service); |
Check notice
Code scanning / CodeQL
Syntax error
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #9945 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 227 227
Lines 4946 4946
Branches 1148 1148
=========================================
Hits 4946 4946 ☔ View full report in Codecov by Sentry. |
|
They. Thanks a lot! I'm traveling this week and next week and will check asap once I'm back. |
|
@satanTime I created a discussion so it will be easier to follow this. If you agree, I would like to cancel this PR and split it into multiple:
Please let me know so I can make the adjustments. |
|
What is the status of this? Been wanting this feature for a long time |
|
There is a discussion on how this will work. You can see it in #9950. There is some decisions that need to be made regarding the base schematic. Currently, it is pending due to @satanTime not being available. |
f9aa723 to
97bfded
Compare
5c06579 to
6a41f0c
Compare
Adds the schematic for a service, initial draft.
Starts the development of #6293