<commit_before>/*global describe, it*/
var expect = require('../unexpected-with-plugins'),
    AssetGraph = require('../../lib/');

describe('relations/HtmlDart', function () {
    it('should handle a simple test case', function (done) {
        new AssetGraph({root: __dirname + '/../../testdata/relations/HtmlDart/'})
            .loadAssets('index.html')
            .populate()
            .queue(function (assetGraph) {
                expect(assetGraph, 'to contain relation');
                expect(assetGraph.findRelations()[0].href, 'to equal', 'app.dart');
                expect(assetGraph.findAssets({type: 'Dart'})[0].text, 'to equal', '\'I am Dart\'\n');
            })
            .run(done);
    });
});
<commit_msg>Improve test coverage for HtmlDart relation<commit_after>/*global describe, it*/
var expect = require('../unexpected-with-plugins'),
    AssetGraph = require('../../lib/');

describe('relations/HtmlDart', function () {
    it('should handle a simple test case', function (done) {
        new AssetGraph({root: __dirname + '/../../testdata/relations/HtmlDart/'})
            .loadAssets('index.html')
            .populate()
            .queue(function (assetGraph) {
                expect(assetGraph, 'to contain relation');
                expect(assetGraph.findRelations()[0].href, 'to equal', 'app.dart');
                expect(assetGraph.findAssets({type: 'Dart'})[0].text, 'to equal', '\'I am Dart\'\n');
            })
            .run(done);
    });

    it('should not inline Dart assets (unsupported)', function (done) {
        new AssetGraph({root: __dirname + '/../../testdata/relations/HtmlDart/'})
            .loadAssets('index.html')
            .populate()
            .queue(function (assetGraph) {
                expect(assetGraph, 'to contain assets', { type: 'Dart', isInline: false }, 1);
            })
            .inlineRelations('HtmlDart')
            .queue(function (assetGraph) {
                expect(assetGraph, 'to contain assets', { type: 'Dart', isInline: false }, 1);
            })
            .run(done);
    });
});

{'fraction_non_alphanumeric': 0.17590822179732313, 'fraction_numerical': 0.0028680688336520078, 'mean_word_length': 2.1954198473282442, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5495057', 'n_tokens_mistral': 612, 'n_tokens_neox': 583, 'n_words': 127}