<commit_before>window.SapphireTest = angular.module 'app', ['ngRoute', 'sp.client']

SapphireTest.config ['$routeProvider', 'SpViewBuilderProvider', ($routeProvider, SpViewBuilderProvider) ->
	$routeProvider
		.when '/about', {
			templateUrl: "/assets/about.html"
		}
		.when '/:slug*', {
			template: SpViewBuilderProvider.template
			controller: 'SpViewController'			
		}
]

SapphireTest.run ['SpViewBuilder', (SpViewBuilder) ->
	console.log 'SpViewBuilder initialized.'
]

SapphireTest.factory 'BlockService', ['$http', ($http) ->
	service = 
		blocks: {}
		find_by_slug: (slug) ->
			if blocks[slug]
				blocks[slug]
			else
				$http.get("/api/content-blocks/slug/#{slug}")<commit_msg>Remove unnecessary controller for view builder in test app<commit_after>window.SapphireTest = angular.module 'app', ['ngRoute', 'sp.client']

SapphireTest.config ['$routeProvider', 'SpViewBuilderProvider', ($routeProvider, SpViewBuilderProvider) ->
	$routeProvider
		.when '/about', {
			templateUrl: "/assets/about.html"
		}
		.when '/:slug*', {
			template: SpViewBuilderProvider.template		
		}
]

SapphireTest.run ['SpViewBuilder', (SpViewBuilder) ->
	console.log 'SpViewBuilder initialized.'
]

SapphireTest.factory 'BlockService', ['$http', ($http) ->
	service = 
		blocks: {}
		find_by_slug: (slug) ->
			if blocks[slug]
				blocks[slug]
			else
				$http.get("/api/content-blocks/slug/#{slug}")
{'fraction_non_alphanumeric': 0.16451149425287356, 'fraction_numerical': 0.0, 'mean_word_length': 4.594377510040161, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 11, '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': '1877836', 'n_tokens_mistral': 513, 'n_tokens_neox': 472, 'n_words': 85}