Skip to content

Latest commit

 

History

History

board_uploader

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

Board Uploader

style: very good analysis Powered by Mason License: MIT

Crossword board uploader.

Usage 💻

This package is responsible for dividing the board into sections and uploading it to Firestore.

Dividing the board in sections

Add a board.txt file inside the assets folder with the board generated by the board_generator_playground package. Once the board is generated, create the sections and upload them to Firestore by running:

dart lib/upload_board.dart

In case you want to update the sections size, do so in the create_sections.dart file before creating the sections.

Note: When creating the sections you will need a service account to upload them to Firestore. Set the GOOGLE_APPLICATION_CREDENTIALS environment variable to the path of your service account.

Running Tests 🧪

The coverage in this package is not enforced at a 100% due to the nature of testing the algorithm with only a few words.

To run all unit tests:

dart pub global activate coverage 1.2.0
dart test --coverage=coverage
dart pub global run coverage:format_coverage --lcov --in=coverage --out=coverage/lcov.info

To view the generated coverage report you can use lcov.

# Generate Coverage Report
genhtml coverage/lcov.info -o coverage/

# Open Coverage Report
open coverage/index.html