Azure / ng-deploy-azure

Deploy Angular apps to Azure using the Angular CLI
MIT License
78 stars 39 forks source link

change file list to include directories - fixes #26 #28

Closed shmool closed 5 years ago

shmool commented 5 years ago

Description

Change the configuration of glob to get all the files including files in directories in the dist/<project-name/ directory. A wrong configuration resulted in ignoring the files in subdirectories. Also, the result file paths were prefixed with '/' which needed to be removed. The fix prevents this.

Type of change

How to Test

  1. Add files to the assets folder in the Angular project.
  2. Build the project.
  3. Run the deploy command. Make sure the assets folder with its content is deployed.

Unit testing:

  1. Mock a directory with files and subdirectories with files. (Empty subdirectories should not be deployed)
  2. Test the getFiles() function in src/builders/actions/deploy.ts to return a list of files which includes the files in the subdirectory.

Closing issues

closes #26

Assignee

@shmool