[
]
(https://bintray.com/hmrc/releases/cc-frontend/_latestVersion)
The Childcare Calculator will help parents quickly self-assess the options for their childcare support, allowing them to make a decision on which scheme will best suit their needs. The Childcare Calculator will calculate the data input by the users, inform them of their eligibility and how much support that they could receive for the Tax-Free Childcare (TFC), Tax Credits (TC) and Employer-Supported Childcare (ESC) schemes.
The Childcare Calculator invokes cc-eligibility microservice(Eligibility documentation) and cc-calculator microservice(Calculator documentation) to get the desired results.
The Childcare Calculator has a feature where in users can do email registration to send the email the calculator invokes cc-email-capture microserive(Email capture documentation)
The Childcare Calculator Frontend service, collects the data input by the users from the fields on the presented pages. This data is collated and passed to the Childcare Calculator backend processes. The results are returned to the Childcare Calculator Frontend service to display to the user.
-
Endpoint URL : /childcare-calculator
-
Port Number : 9366
The application uses Grunt to manage the assets and perform pre-deployment compilation of custom stylesheets/javascript files etc.
- Clone the repository
- Install node.js
..*
sudo apt-get install nodejs
..* If you're using a Linux distro you may need to installsudo apt-get install nodejs-legacy
- sudo apt-get install npm
- Run
./setupgrunt.sh
- Run
sbt test
If you need to manually compile the assets then in the terminal run the following:
cd $workspace/assets/js
grunt
NOTE: This will run a local instance of browserSync, this is accessible at http://localhost:3000/childcare-calculator
NOTE: There is currently a complication issue with custom styles when running the service through Service Manager: sm --start CC_FRONTEND -f
All assets are compiled into the /public
folder which has a route defined within the conf/cc.routes
file
NOTE: assets-frontend
is automatically pulled in from the govuk template, you have to have a json configuration within a .conf
file
For example:
assets {
version = "2.50.0"
url = "http://localhost:9032/assets/"
}
To run the unit tests for the application run the following:
cd $workspace
sbt test
To run a single unit test/spec
cd $workspace
sbt
test-only */path/to/unitspec/Example*
- Example being the class name of your UnitSpec
To run the test coverage suite scoverage
sbt clean scoverage:test
NOTE: Cucumber/acceptance tests are available in a separate project at:
http://github.tools.tax.service.gov.uk/ddcn/cc-acceptance-tests
To provide messages files with variables that are passed in then use the following format:
@Messages("cc.compare.total.household.spend", totalHouseholdSpend)
cc.compare.total.household.spend = You told us your childcare costs are {0} a month
This code is open source software licensed under the Apache 2.0 License.