initial tryout
This commit is contained in:
parent
27245ce959
commit
b08239daba
|
@ -0,0 +1 @@
|
||||||
|
dictee
|
|
@ -0,0 +1,14 @@
|
||||||
|
<component name="libraryTable">
|
||||||
|
<library name="org.junit.jupiter:junit-jupiter-params:5.1.0" type="repository">
|
||||||
|
<properties maven-id="org.junit.jupiter:junit-jupiter-params:5.1.0" />
|
||||||
|
<CLASSES>
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-params/5.1.0/junit-jupiter-params-5.1.0.jar!/" />
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/apiguardian/apiguardian-api/1.0.0/apiguardian-api-1.0.0.jar!/" />
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-api/5.1.0/junit-jupiter-api-5.1.0.jar!/" />
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/opentest4j/opentest4j/1.0.0/opentest4j-1.0.0.jar!/" />
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/junit/platform/junit-platform-commons/1.1.0/junit-platform-commons-1.1.0.jar!/" />
|
||||||
|
</CLASSES>
|
||||||
|
<JAVADOC />
|
||||||
|
<SOURCES />
|
||||||
|
</library>
|
||||||
|
</component>
|
|
@ -0,0 +1,6 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_9" default="true" project-jdk-name="9.0" project-jdk-type="JavaSDK">
|
||||||
|
<output url="file://$PROJECT_DIR$/out" />
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,8 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectModuleManager">
|
||||||
|
<modules>
|
||||||
|
<module fileurl="file://$PROJECT_DIR$/java.iml" filepath="$PROJECT_DIR$/java.iml" />
|
||||||
|
</modules>
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,588 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ChangeListManager">
|
||||||
|
<list default="true" id="4130292f-5976-40d7-af14-ee176ca64834" name="Default" comment="" />
|
||||||
|
<ignored path="$PROJECT_DIR$/out/" />
|
||||||
|
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
||||||
|
<option name="TRACKING_ENABLED" value="true" />
|
||||||
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
|
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||||
|
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||||
|
</component>
|
||||||
|
<component name="FileEditorManager">
|
||||||
|
<leaf>
|
||||||
|
<file leaf-file-name="Dictee.java" pinned="false" current-in-tab="true">
|
||||||
|
<entry file="file://$PROJECT_DIR$/src/com/brainbaking/dictee/Dictee.java">
|
||||||
|
<provider selected="true" editor-type-id="text-editor">
|
||||||
|
<state relative-caret-position="370">
|
||||||
|
<caret line="49" column="0" lean-forward="true" selection-start-line="49" selection-start-column="0" selection-end-line="49" selection-end-column="0" />
|
||||||
|
<folding>
|
||||||
|
<element signature="imports" expanded="true" />
|
||||||
|
<element signature="e#1018#1024#0" expanded="true" />
|
||||||
|
</folding>
|
||||||
|
</state>
|
||||||
|
</provider>
|
||||||
|
</entry>
|
||||||
|
</file>
|
||||||
|
<file leaf-file-name="Diff.java" pinned="false" current-in-tab="false">
|
||||||
|
<entry file="file://$PROJECT_DIR$/src/com/brainbaking/dictee/Diff.java">
|
||||||
|
<provider selected="true" editor-type-id="text-editor">
|
||||||
|
<state relative-caret-position="256">
|
||||||
|
<caret line="19" column="31" lean-forward="false" selection-start-line="19" selection-start-column="31" selection-end-line="19" selection-end-column="31" />
|
||||||
|
<folding>
|
||||||
|
<element signature="e#172#173#0" expanded="true" />
|
||||||
|
<element signature="e#200#201#0" expanded="true" />
|
||||||
|
<element signature="e#392#393#0" expanded="true" />
|
||||||
|
<element signature="e#432#433#0" expanded="true" />
|
||||||
|
<element signature="e#493#494#0" expanded="true" />
|
||||||
|
<element signature="e#541#542#0" expanded="true" />
|
||||||
|
<element signature="e#597#598#0" expanded="true" />
|
||||||
|
<element signature="e#645#646#0" expanded="true" />
|
||||||
|
<element signature="e#691#692#0" expanded="true" />
|
||||||
|
<element signature="e#750#751#0" expanded="true" />
|
||||||
|
</folding>
|
||||||
|
</state>
|
||||||
|
</provider>
|
||||||
|
</entry>
|
||||||
|
</file>
|
||||||
|
<file leaf-file-name="DicteeTests.java" pinned="false" current-in-tab="false">
|
||||||
|
<entry file="file://$PROJECT_DIR$/test/com/brainbaking/dictee/DicteeTests.java">
|
||||||
|
<provider selected="true" editor-type-id="text-editor">
|
||||||
|
<state relative-caret-position="341">
|
||||||
|
<caret line="20" column="0" lean-forward="true" selection-start-line="20" selection-start-column="0" selection-end-line="20" selection-end-column="0" />
|
||||||
|
<folding>
|
||||||
|
<element signature="imports" expanded="true" />
|
||||||
|
<element signature="e#1807#1808#0" expanded="true" />
|
||||||
|
<element signature="e#1869#1870#0" expanded="true" />
|
||||||
|
</folding>
|
||||||
|
</state>
|
||||||
|
</provider>
|
||||||
|
</entry>
|
||||||
|
</file>
|
||||||
|
</leaf>
|
||||||
|
</component>
|
||||||
|
<component name="FileTemplateManagerImpl">
|
||||||
|
<option name="RECENT_TEMPLATES">
|
||||||
|
<list>
|
||||||
|
<option value="Class" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
<component name="GradleLocalSettings">
|
||||||
|
<option name="externalProjectsViewState">
|
||||||
|
<projects_view />
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
<component name="IdeDocumentHistory">
|
||||||
|
<option name="CHANGED_PATHS">
|
||||||
|
<list>
|
||||||
|
<option value="$PROJECT_DIR$/test/com/brainbaking/dictee/DicteeTests.java" />
|
||||||
|
<option value="$PROJECT_DIR$/src/com/brainbaking/dictee/Diff.java" />
|
||||||
|
<option value="$PROJECT_DIR$/src/com/brainbaking/dictee/Dictee.java" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
<component name="ProjectFrameBounds" extendedState="6">
|
||||||
|
<option name="y" value="23" />
|
||||||
|
<option name="width" value="720" />
|
||||||
|
<option name="height" value="436" />
|
||||||
|
</component>
|
||||||
|
<component name="ProjectView">
|
||||||
|
<navigator currentView="ProjectPane" proportions="" version="1">
|
||||||
|
<flattenPackages />
|
||||||
|
<showMembers />
|
||||||
|
<showModules />
|
||||||
|
<showLibraryContents />
|
||||||
|
<hideEmptyPackages />
|
||||||
|
<abbreviatePackageNames />
|
||||||
|
<autoscrollToSource />
|
||||||
|
<autoscrollFromSource />
|
||||||
|
<sortByType />
|
||||||
|
<manualOrder />
|
||||||
|
<foldersAlwaysOnTop value="true" />
|
||||||
|
</navigator>
|
||||||
|
<panes>
|
||||||
|
<pane id="AndroidView" />
|
||||||
|
<pane id="PackagesPane" />
|
||||||
|
<pane id="Scope" />
|
||||||
|
<pane id="Scratches" />
|
||||||
|
<pane id="ProjectPane">
|
||||||
|
<subPane>
|
||||||
|
<expand>
|
||||||
|
<path>
|
||||||
|
<item name="dictee" type="b2602c69:ProjectViewProjectNode" />
|
||||||
|
<item name="java" type="462c0819:PsiDirectoryNode" />
|
||||||
|
</path>
|
||||||
|
<path>
|
||||||
|
<item name="dictee" type="b2602c69:ProjectViewProjectNode" />
|
||||||
|
<item name="java" type="462c0819:PsiDirectoryNode" />
|
||||||
|
<item name="src" type="462c0819:PsiDirectoryNode" />
|
||||||
|
</path>
|
||||||
|
<path>
|
||||||
|
<item name="dictee" type="b2602c69:ProjectViewProjectNode" />
|
||||||
|
<item name="java" type="462c0819:PsiDirectoryNode" />
|
||||||
|
<item name="src" type="462c0819:PsiDirectoryNode" />
|
||||||
|
<item name="dictee" type="462c0819:PsiDirectoryNode" />
|
||||||
|
</path>
|
||||||
|
<path>
|
||||||
|
<item name="dictee" type="b2602c69:ProjectViewProjectNode" />
|
||||||
|
<item name="java" type="462c0819:PsiDirectoryNode" />
|
||||||
|
<item name="test" type="462c0819:PsiDirectoryNode" />
|
||||||
|
</path>
|
||||||
|
<path>
|
||||||
|
<item name="dictee" type="b2602c69:ProjectViewProjectNode" />
|
||||||
|
<item name="java" type="462c0819:PsiDirectoryNode" />
|
||||||
|
<item name="test" type="462c0819:PsiDirectoryNode" />
|
||||||
|
<item name="dictee" type="462c0819:PsiDirectoryNode" />
|
||||||
|
</path>
|
||||||
|
<path>
|
||||||
|
<item name="dictee" type="b2602c69:ProjectViewProjectNode" />
|
||||||
|
<item name="External Libraries" type="cb654da1:ExternalLibrariesNode" />
|
||||||
|
</path>
|
||||||
|
</expand>
|
||||||
|
<select />
|
||||||
|
</subPane>
|
||||||
|
</pane>
|
||||||
|
</panes>
|
||||||
|
</component>
|
||||||
|
<component name="PropertiesComponent">
|
||||||
|
<property name="settings.editor.selected.configurable" value="reference.projectsettings.compiler.javacompiler" />
|
||||||
|
<property name="Downloaded.Files.Path.Enabled" value="false" />
|
||||||
|
<property name="Repository.Attach.JavaDocs" value="false" />
|
||||||
|
<property name="Repository.Attach.Sources" value="false" />
|
||||||
|
<property name="project.structure.last.edited" value="Libraries" />
|
||||||
|
<property name="project.structure.proportion" value="0.0" />
|
||||||
|
<property name="project.structure.side.proportion" value="0.2" />
|
||||||
|
</component>
|
||||||
|
<component name="RunDashboard">
|
||||||
|
<option name="ruleStates">
|
||||||
|
<list>
|
||||||
|
<RuleState>
|
||||||
|
<option name="name" value="ConfigurationTypeDashboardGroupingRule" />
|
||||||
|
</RuleState>
|
||||||
|
<RuleState>
|
||||||
|
<option name="name" value="StatusDashboardGroupingRule" />
|
||||||
|
</RuleState>
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
<component name="RunManager" selected="JUnit.DicteeTests">
|
||||||
|
<configuration default="true" type="Applet" factoryName="Applet">
|
||||||
|
<module />
|
||||||
|
<option name="HTML_USED" value="false" />
|
||||||
|
<option name="WIDTH" value="400" />
|
||||||
|
<option name="HEIGHT" value="300" />
|
||||||
|
<option name="POLICY_FILE" value="$APPLICATION_HOME_DIR$/bin/appletviewer.policy" />
|
||||||
|
</configuration>
|
||||||
|
<configuration default="true" type="Application" factoryName="Application">
|
||||||
|
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
|
||||||
|
<option name="MAIN_CLASS_NAME" />
|
||||||
|
<option name="VM_PARAMETERS" />
|
||||||
|
<option name="PROGRAM_PARAMETERS" />
|
||||||
|
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH" />
|
||||||
|
<option name="ENABLE_SWING_INSPECTOR" value="false" />
|
||||||
|
<option name="ENV_VARIABLES" />
|
||||||
|
<option name="PASS_PARENT_ENVS" value="true" />
|
||||||
|
<module name="" />
|
||||||
|
<envs />
|
||||||
|
</configuration>
|
||||||
|
<configuration name="DicteeTests" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
|
||||||
|
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
|
||||||
|
<pattern>
|
||||||
|
<option name="PATTERN" value="com.brainbaking.dictee.*" />
|
||||||
|
<option name="ENABLED" value="true" />
|
||||||
|
</pattern>
|
||||||
|
</extension>
|
||||||
|
<module name="java" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH" />
|
||||||
|
<option name="PACKAGE_NAME" value="com.brainbaking.dictee" />
|
||||||
|
<option name="MAIN_CLASS_NAME" value="com.brainbaking.dictee.DicteeTests" />
|
||||||
|
<option name="METHOD_NAME" />
|
||||||
|
<option name="TEST_OBJECT" value="class" />
|
||||||
|
<option name="VM_PARAMETERS" value="-ea" />
|
||||||
|
<option name="PARAMETERS" />
|
||||||
|
<option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
|
||||||
|
<option name="ENV_VARIABLES" />
|
||||||
|
<option name="PASS_PARENT_ENVS" value="true" />
|
||||||
|
<option name="TEST_SEARCH_SCOPE">
|
||||||
|
<value defaultName="singleModule" />
|
||||||
|
</option>
|
||||||
|
<envs />
|
||||||
|
<patterns />
|
||||||
|
</configuration>
|
||||||
|
<configuration name="DicteeTests.basisGevallen_zelfdeGrootte" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
|
||||||
|
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
|
||||||
|
<pattern>
|
||||||
|
<option name="PATTERN" value="com.brainbaking.dictee.*" />
|
||||||
|
<option name="ENABLED" value="true" />
|
||||||
|
</pattern>
|
||||||
|
</extension>
|
||||||
|
<module name="java" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH" />
|
||||||
|
<option name="PACKAGE_NAME" value="com.brainbaking.dictee" />
|
||||||
|
<option name="MAIN_CLASS_NAME" value="com.brainbaking.dictee.DicteeTests" />
|
||||||
|
<option name="METHOD_NAME" value="basisGevallen_zelfdeGrootte(java.lang.String)" />
|
||||||
|
<option name="TEST_OBJECT" value="method" />
|
||||||
|
<option name="VM_PARAMETERS" value="-ea" />
|
||||||
|
<option name="PARAMETERS" />
|
||||||
|
<option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
|
||||||
|
<option name="ENV_VARIABLES" />
|
||||||
|
<option name="PASS_PARENT_ENVS" value="true" />
|
||||||
|
<option name="TEST_SEARCH_SCOPE">
|
||||||
|
<value defaultName="singleModule" />
|
||||||
|
</option>
|
||||||
|
<envs />
|
||||||
|
<patterns />
|
||||||
|
</configuration>
|
||||||
|
<configuration name="DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
|
||||||
|
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
|
||||||
|
<pattern>
|
||||||
|
<option name="PATTERN" value="com.brainbaking.dictee.*" />
|
||||||
|
<option name="ENABLED" value="true" />
|
||||||
|
</pattern>
|
||||||
|
</extension>
|
||||||
|
<module name="java" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH" />
|
||||||
|
<option name="PACKAGE_NAME" value="com.brainbaking.dictee" />
|
||||||
|
<option name="MAIN_CLASS_NAME" value="com.brainbaking.dictee.DicteeTests" />
|
||||||
|
<option name="METHOD_NAME" value="combinatieGeval_hoofdLetterEnKleineLetters(java.lang.String)" />
|
||||||
|
<option name="TEST_OBJECT" value="method" />
|
||||||
|
<option name="VM_PARAMETERS" value="-ea" />
|
||||||
|
<option name="PARAMETERS" />
|
||||||
|
<option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
|
||||||
|
<option name="ENV_VARIABLES" />
|
||||||
|
<option name="PASS_PARENT_ENVS" value="true" />
|
||||||
|
<option name="TEST_SEARCH_SCOPE">
|
||||||
|
<value defaultName="singleModule" />
|
||||||
|
</option>
|
||||||
|
<envs />
|
||||||
|
<patterns />
|
||||||
|
</configuration>
|
||||||
|
<configuration default="true" type="JUnit" factoryName="JUnit">
|
||||||
|
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
|
||||||
|
<module name="" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH" />
|
||||||
|
<option name="PACKAGE_NAME" />
|
||||||
|
<option name="MAIN_CLASS_NAME" />
|
||||||
|
<option name="METHOD_NAME" />
|
||||||
|
<option name="TEST_OBJECT" value="class" />
|
||||||
|
<option name="VM_PARAMETERS" value="-ea" />
|
||||||
|
<option name="PARAMETERS" />
|
||||||
|
<option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
|
||||||
|
<option name="ENV_VARIABLES" />
|
||||||
|
<option name="PASS_PARENT_ENVS" value="true" />
|
||||||
|
<option name="TEST_SEARCH_SCOPE">
|
||||||
|
<value defaultName="singleModule" />
|
||||||
|
</option>
|
||||||
|
<envs />
|
||||||
|
<patterns />
|
||||||
|
</configuration>
|
||||||
|
<configuration default="true" type="Remote" factoryName="Remote">
|
||||||
|
<option name="USE_SOCKET_TRANSPORT" value="true" />
|
||||||
|
<option name="SERVER_MODE" value="false" />
|
||||||
|
<option name="SHMEM_ADDRESS" value="javadebug" />
|
||||||
|
<option name="HOST" value="localhost" />
|
||||||
|
<option name="PORT" value="5005" />
|
||||||
|
</configuration>
|
||||||
|
<configuration default="true" type="TestNG" factoryName="TestNG">
|
||||||
|
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
|
||||||
|
<module name="" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
|
||||||
|
<option name="ALTERNATIVE_JRE_PATH" />
|
||||||
|
<option name="SUITE_NAME" />
|
||||||
|
<option name="PACKAGE_NAME" />
|
||||||
|
<option name="MAIN_CLASS_NAME" />
|
||||||
|
<option name="METHOD_NAME" />
|
||||||
|
<option name="GROUP_NAME" />
|
||||||
|
<option name="TEST_OBJECT" value="CLASS" />
|
||||||
|
<option name="VM_PARAMETERS" value="-ea" />
|
||||||
|
<option name="PARAMETERS" />
|
||||||
|
<option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
|
||||||
|
<option name="OUTPUT_DIRECTORY" />
|
||||||
|
<option name="ANNOTATION_TYPE" />
|
||||||
|
<option name="ENV_VARIABLES" />
|
||||||
|
<option name="PASS_PARENT_ENVS" value="true" />
|
||||||
|
<option name="TEST_SEARCH_SCOPE">
|
||||||
|
<value defaultName="singleModule" />
|
||||||
|
</option>
|
||||||
|
<option name="USE_DEFAULT_REPORTERS" value="false" />
|
||||||
|
<option name="PROPERTIES_FILE" />
|
||||||
|
<envs />
|
||||||
|
<properties />
|
||||||
|
<listeners />
|
||||||
|
</configuration>
|
||||||
|
<configuration default="true" type="#org.jetbrains.idea.devkit.run.PluginConfigurationType" factoryName="Plugin">
|
||||||
|
<module name="" />
|
||||||
|
<option name="VM_PARAMETERS" value="-Xmx512m -Xms256m -XX:MaxPermSize=250m -ea" />
|
||||||
|
<option name="PROGRAM_PARAMETERS" />
|
||||||
|
<predefined_log_file id="idea.log" enabled="true" />
|
||||||
|
</configuration>
|
||||||
|
<list size="3">
|
||||||
|
<item index="0" class="java.lang.String" itemvalue="JUnit.DicteeTests" />
|
||||||
|
<item index="1" class="java.lang.String" itemvalue="JUnit.DicteeTests.basisGevallen_zelfdeGrootte" />
|
||||||
|
<item index="2" class="java.lang.String" itemvalue="JUnit.DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" />
|
||||||
|
</list>
|
||||||
|
<recent_temporary>
|
||||||
|
<list size="3">
|
||||||
|
<item index="0" class="java.lang.String" itemvalue="JUnit.DicteeTests" />
|
||||||
|
<item index="1" class="java.lang.String" itemvalue="JUnit.DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" />
|
||||||
|
<item index="2" class="java.lang.String" itemvalue="JUnit.DicteeTests.basisGevallen_zelfdeGrootte" />
|
||||||
|
</list>
|
||||||
|
</recent_temporary>
|
||||||
|
</component>
|
||||||
|
<component name="ShelveChangesManager" show_recycled="false">
|
||||||
|
<option name="remove_strategy" value="false" />
|
||||||
|
</component>
|
||||||
|
<component name="SvnConfiguration">
|
||||||
|
<configuration />
|
||||||
|
</component>
|
||||||
|
<component name="TaskManager">
|
||||||
|
<task active="true" id="Default" summary="Default task">
|
||||||
|
<changelist id="4130292f-5976-40d7-af14-ee176ca64834" name="Default" comment="" />
|
||||||
|
<created>1521054378892</created>
|
||||||
|
<option name="number" value="Default" />
|
||||||
|
<option name="presentableId" value="Default" />
|
||||||
|
<updated>1521054378892</updated>
|
||||||
|
</task>
|
||||||
|
<servers />
|
||||||
|
</component>
|
||||||
|
<component name="TestHistory">
|
||||||
|
<history-entry file="DicteeTests - 2018.03.14 at 22h 11m 09s.xml">
|
||||||
|
<configuration name="DicteeTests" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests - 2018.03.14 at 22h 12m 58s.xml">
|
||||||
|
<configuration name="DicteeTests" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests - 2018.03.14 at 22h 19m 54s.xml">
|
||||||
|
<configuration name="DicteeTests" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests - 2018.03.14 at 22h 20m 38s.xml">
|
||||||
|
<configuration name="DicteeTests" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests_combinatieGeval_hoofdLetterEnKleineLetters - 2018.03.14 at 22h 14m 42s.xml">
|
||||||
|
<configuration name="DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests_combinatieGeval_hoofdLetterEnKleineLetters - 2018.03.14 at 22h 14m 58s.xml">
|
||||||
|
<configuration name="DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests_combinatieGeval_hoofdLetterEnKleineLetters - 2018.03.14 at 22h 16m 00s.xml">
|
||||||
|
<configuration name="DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests_combinatieGeval_hoofdLetterEnKleineLetters - 2018.03.14 at 22h 17m 00s.xml">
|
||||||
|
<configuration name="DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests_combinatieGeval_hoofdLetterEnKleineLetters - 2018.03.14 at 22h 18m 30s.xml">
|
||||||
|
<configuration name="DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
<history-entry file="DicteeTests_combinatieGeval_hoofdLetterEnKleineLetters - 2018.03.14 at 22h 19m 45s.xml">
|
||||||
|
<configuration name="DicteeTests.combinatieGeval_hoofdLetterEnKleineLetters" configurationId="JUnit" />
|
||||||
|
</history-entry>
|
||||||
|
</component>
|
||||||
|
<component name="ToolWindowManager">
|
||||||
|
<frame x="0" y="23" width="1280" height="873" extended-state="6" />
|
||||||
|
<layout>
|
||||||
|
<window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32958803" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Palette	" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Image Layers" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Capture Analysis" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="true" content_ui="tabs" />
|
||||||
|
<window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="false" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Run" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.32958803" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Capture Tool" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.28125" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
|
||||||
|
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Theme Preview" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="true" content_ui="tabs" />
|
||||||
|
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.39950064" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
|
||||||
|
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||||
|
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
|
||||||
|
</layout>
|
||||||
|
</component>
|
||||||
|
<component name="VcsContentAnnotationSettings">
|
||||||
|
<option name="myLimit" value="2678400000" />
|
||||||
|
</component>
|
||||||
|
<component name="XDebuggerManager">
|
||||||
|
<breakpoint-manager>
|
||||||
|
<breakpoints>
|
||||||
|
<line-breakpoint enabled="true" type="java-line">
|
||||||
|
<url>file://$PROJECT_DIR$/src/com/brainbaking/dictee/Dictee.java</url>
|
||||||
|
<line>56</line>
|
||||||
|
<properties />
|
||||||
|
<option name="timeStamp" value="2" />
|
||||||
|
</line-breakpoint>
|
||||||
|
<line-breakpoint enabled="true" type="java-line">
|
||||||
|
<url>file://$PROJECT_DIR$/src/com/brainbaking/dictee/Dictee.java</url>
|
||||||
|
<line>37</line>
|
||||||
|
<properties />
|
||||||
|
<option name="timeStamp" value="3" />
|
||||||
|
</line-breakpoint>
|
||||||
|
</breakpoints>
|
||||||
|
<option name="time" value="4" />
|
||||||
|
</breakpoint-manager>
|
||||||
|
<watches-manager />
|
||||||
|
</component>
|
||||||
|
<component name="debuggerHistoryManager">
|
||||||
|
<expressions id="evaluateExpression">
|
||||||
|
<expression>
|
||||||
|
<expression-string>input.split("\\|")</expression-string>
|
||||||
|
<language-id>JAVA</language-id>
|
||||||
|
<evaluation-mode>EXPRESSION</evaluation-mode>
|
||||||
|
</expression>
|
||||||
|
<expression>
|
||||||
|
<expression-string>input.split("\|")</expression-string>
|
||||||
|
<language-id>JAVA</language-id>
|
||||||
|
<evaluation-mode>EXPRESSION</evaluation-mode>
|
||||||
|
</expression>
|
||||||
|
<expression>
|
||||||
|
<expression-string>input.split("|")</expression-string>
|
||||||
|
<language-id>JAVA</language-id>
|
||||||
|
<evaluation-mode>EXPRESSION</evaluation-mode>
|
||||||
|
</expression>
|
||||||
|
</expressions>
|
||||||
|
</component>
|
||||||
|
<component name="editorHistoryManager">
|
||||||
|
<entry file="jar:///Library/Java/JavaVirtualMachines/jdk-9.0.4.jdk/Contents/Home/lib/src.zip!/java.base/java/lang/NumberFormatException.java">
|
||||||
|
<provider selected="true" editor-type-id="text-editor">
|
||||||
|
<state relative-caret-position="169">
|
||||||
|
<caret line="64" column="0" lean-forward="false" selection-start-line="64" selection-start-column="0" selection-end-line="64" selection-end-column="0" />
|
||||||
|
<folding />
|
||||||
|
</state>
|
||||||
|
</provider>
|
||||||
|
</entry>
|
||||||
|
<entry file="file://$PROJECT_DIR$/test/com/brainbaking/dictee/DicteeTests.java">
|
||||||
|
<provider selected="true" editor-type-id="text-editor">
|
||||||
|
<state relative-caret-position="341">
|
||||||
|
<caret line="20" column="0" lean-forward="true" selection-start-line="20" selection-start-column="0" selection-end-line="20" selection-end-column="0" />
|
||||||
|
<folding>
|
||||||
|
<element signature="imports" expanded="true" />
|
||||||
|
<element signature="e#1807#1808#0" expanded="true" />
|
||||||
|
<element signature="e#1869#1870#0" expanded="true" />
|
||||||
|
</folding>
|
||||||
|
</state>
|
||||||
|
</provider>
|
||||||
|
</entry>
|
||||||
|
<entry file="file://$PROJECT_DIR$/src/com/brainbaking/dictee/Diff.java">
|
||||||
|
<provider selected="true" editor-type-id="text-editor">
|
||||||
|
<state relative-caret-position="256">
|
||||||
|
<caret line="19" column="31" lean-forward="false" selection-start-line="19" selection-start-column="31" selection-end-line="19" selection-end-column="31" />
|
||||||
|
<folding>
|
||||||
|
<element signature="e#172#173#0" expanded="true" />
|
||||||
|
<element signature="e#200#201#0" expanded="true" />
|
||||||
|
<element signature="e#392#393#0" expanded="true" />
|
||||||
|
<element signature="e#432#433#0" expanded="true" />
|
||||||
|
<element signature="e#493#494#0" expanded="true" />
|
||||||
|
<element signature="e#541#542#0" expanded="true" />
|
||||||
|
<element signature="e#597#598#0" expanded="true" />
|
||||||
|
<element signature="e#645#646#0" expanded="true" />
|
||||||
|
<element signature="e#691#692#0" expanded="true" />
|
||||||
|
<element signature="e#750#751#0" expanded="true" />
|
||||||
|
</folding>
|
||||||
|
</state>
|
||||||
|
</provider>
|
||||||
|
</entry>
|
||||||
|
<entry file="file://$PROJECT_DIR$/src/com/brainbaking/dictee/Dictee.java">
|
||||||
|
<provider selected="true" editor-type-id="text-editor">
|
||||||
|
<state relative-caret-position="370">
|
||||||
|
<caret line="49" column="0" lean-forward="true" selection-start-line="49" selection-start-column="0" selection-end-line="49" selection-end-column="0" />
|
||||||
|
<folding>
|
||||||
|
<element signature="imports" expanded="true" />
|
||||||
|
<element signature="e#1018#1024#0" expanded="true" />
|
||||||
|
</folding>
|
||||||
|
</state>
|
||||||
|
</provider>
|
||||||
|
</entry>
|
||||||
|
</component>
|
||||||
|
<component name="masterDetails">
|
||||||
|
<states>
|
||||||
|
<state key="ArtifactsStructureConfigurable.UI">
|
||||||
|
<settings>
|
||||||
|
<artifact-editor />
|
||||||
|
<splitter-proportions>
|
||||||
|
<option name="proportions">
|
||||||
|
<list>
|
||||||
|
<option value="0.2" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</splitter-proportions>
|
||||||
|
</settings>
|
||||||
|
</state>
|
||||||
|
<state key="FacetStructureConfigurable.UI">
|
||||||
|
<settings>
|
||||||
|
<last-edited>No facets are configured</last-edited>
|
||||||
|
<splitter-proportions>
|
||||||
|
<option name="proportions">
|
||||||
|
<list>
|
||||||
|
<option value="0.2" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</splitter-proportions>
|
||||||
|
</settings>
|
||||||
|
</state>
|
||||||
|
<state key="GlobalLibrariesConfigurable.UI">
|
||||||
|
<settings>
|
||||||
|
<splitter-proportions>
|
||||||
|
<option name="proportions">
|
||||||
|
<list>
|
||||||
|
<option value="0.2" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</splitter-proportions>
|
||||||
|
</settings>
|
||||||
|
</state>
|
||||||
|
<state key="JdkListConfigurable.UI">
|
||||||
|
<settings>
|
||||||
|
<last-edited>9.0</last-edited>
|
||||||
|
<splitter-proportions>
|
||||||
|
<option name="proportions">
|
||||||
|
<list>
|
||||||
|
<option value="0.2" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</splitter-proportions>
|
||||||
|
</settings>
|
||||||
|
</state>
|
||||||
|
<state key="ModuleStructureConfigurable.UI">
|
||||||
|
<settings>
|
||||||
|
<last-edited>java</last-edited>
|
||||||
|
<splitter-proportions>
|
||||||
|
<option name="proportions">
|
||||||
|
<list>
|
||||||
|
<option value="0.2" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</splitter-proportions>
|
||||||
|
</settings>
|
||||||
|
</state>
|
||||||
|
<state key="ProjectLibrariesConfigurable.UI">
|
||||||
|
<settings>
|
||||||
|
<last-edited>org.junit.jupiter:junit-jupiter-params:5.1.0</last-edited>
|
||||||
|
<splitter-proportions>
|
||||||
|
<option name="proportions">
|
||||||
|
<list>
|
||||||
|
<option value="0.2" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</splitter-proportions>
|
||||||
|
</settings>
|
||||||
|
</state>
|
||||||
|
</states>
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,25 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<module type="JAVA_MODULE" version="4">
|
||||||
|
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
||||||
|
<exclude-output />
|
||||||
|
<content url="file://$MODULE_DIR$">
|
||||||
|
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
|
||||||
|
<sourceFolder url="file://$MODULE_DIR$/test" isTestSource="true" />
|
||||||
|
</content>
|
||||||
|
<orderEntry type="inheritedJdk" />
|
||||||
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
<orderEntry type="module-library" scope="TEST">
|
||||||
|
<library name="JUnit5.0">
|
||||||
|
<CLASSES>
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-api/5.0.0/junit-jupiter-api-5.0.0.jar!/" />
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/apiguardian/apiguardian-api/1.0.0/apiguardian-api-1.0.0.jar!/" />
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/opentest4j/opentest4j/1.0.0/opentest4j-1.0.0.jar!/" />
|
||||||
|
<root url="jar://$MAVEN_REPOSITORY$/org/junit/platform/junit-platform-commons/1.0.0/junit-platform-commons-1.0.0.jar!/" />
|
||||||
|
</CLASSES>
|
||||||
|
<JAVADOC />
|
||||||
|
<SOURCES />
|
||||||
|
</library>
|
||||||
|
</orderEntry>
|
||||||
|
<orderEntry type="library" name="org.junit.jupiter:junit-jupiter-params:5.1.0" level="project" />
|
||||||
|
</component>
|
||||||
|
</module>
|
|
@ -0,0 +1,68 @@
|
||||||
|
package com.brainbaking.dictee;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Stack;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
public class Dictee {
|
||||||
|
|
||||||
|
private final String invoer;
|
||||||
|
private final String referentie;
|
||||||
|
|
||||||
|
public Dictee(String invoer, String referentie) {
|
||||||
|
this.invoer = invoer;
|
||||||
|
this.referentie = referentie;
|
||||||
|
|
||||||
|
System.out.println("Dictee: invoer \t" + invoer);
|
||||||
|
System.out.println("Dictee: referentie \t" + referentie);
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<Character> getInvoerChars() {
|
||||||
|
return invoer.chars().mapToObj(e->((char)e)).collect(Collectors.toList());
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<Character> getReferentie() {
|
||||||
|
return referentie.chars().mapToObj(e->((char)e)).collect(Collectors.toList());
|
||||||
|
}
|
||||||
|
|
||||||
|
public int verbeter() {
|
||||||
|
List<Character> in = getInvoerChars();
|
||||||
|
List<Character> inLower = in.stream().map(Character::toLowerCase).collect(Collectors.toList());
|
||||||
|
List<Diff> diffs = new ArrayList<Diff>();
|
||||||
|
|
||||||
|
for(int i = 0; i < getReferentie().size(); i++) {
|
||||||
|
char refCurr = getReferentie().get(i);
|
||||||
|
|
||||||
|
int index = in.indexOf(refCurr);
|
||||||
|
if(index >= 0) {
|
||||||
|
in.remove(index);
|
||||||
|
} else {
|
||||||
|
int lowerIndex = inLower.indexOf(Character.toLowerCase(refCurr));
|
||||||
|
if(lowerIndex >= 0) {
|
||||||
|
diffs.add(Diff.hoofdletter(refCurr, i));
|
||||||
|
|
||||||
|
in.remove((Character) Character.toLowerCase(refCurr));
|
||||||
|
in.remove((Character) Character.toUpperCase(refCurr));
|
||||||
|
} else {
|
||||||
|
diffs.add(Diff.create(refCurr, i));
|
||||||
|
|
||||||
|
in.remove(getInvoerChars().get(i));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
List<Diff> diffsInLengte = in.stream().map(Diff::create).collect(Collectors.toList());
|
||||||
|
if(diffsInLengte.size() != diffs.size()) {
|
||||||
|
diffs.addAll(diffsInLengte);
|
||||||
|
}
|
||||||
|
|
||||||
|
diffs.forEach(System.out::println);
|
||||||
|
|
||||||
|
return diffs.stream()
|
||||||
|
.mapToInt(d -> d.getScore())
|
||||||
|
.sum();
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,35 @@
|
||||||
|
package com.brainbaking.dictee;
|
||||||
|
|
||||||
|
public class Diff {
|
||||||
|
|
||||||
|
private final char aChar;
|
||||||
|
private final int refIndex;
|
||||||
|
private final int score;
|
||||||
|
|
||||||
|
public int getScore() {
|
||||||
|
return score;
|
||||||
|
}
|
||||||
|
|
||||||
|
private Diff(char aChar, int index, int score) {
|
||||||
|
this.aChar = aChar;
|
||||||
|
this.refIndex = index;
|
||||||
|
this.score = score;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Diff create(char aChar) {
|
||||||
|
return create(aChar, -1);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Diff hoofdletter(char aChar, int index) {
|
||||||
|
return new Diff(aChar, index, 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Diff create(char aChar, int index) {
|
||||||
|
return new Diff(aChar, index, 2);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return aChar + "@" + refIndex + "-" + score;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,65 @@
|
||||||
|
package com.brainbaking.dictee;
|
||||||
|
|
||||||
|
import org.junit.jupiter.api.Test;
|
||||||
|
import org.junit.jupiter.params.ParameterizedTest;
|
||||||
|
import org.junit.jupiter.params.provider.ValueSource;
|
||||||
|
|
||||||
|
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||||
|
|
||||||
|
public class DicteeTests {
|
||||||
|
|
||||||
|
@ParameterizedTest
|
||||||
|
@ValueSource(strings = {
|
||||||
|
"sup Dikke kerels|wup dikkE kerel|6",
|
||||||
|
"sup Dikke kerels|wup dikkE kerels|4" })
|
||||||
|
public void combinatieGeval_hoofdLetterEnKleineLetters(String input) {
|
||||||
|
Dictee dictee = createDictee(input);
|
||||||
|
int expected = getExpected(input);
|
||||||
|
|
||||||
|
assertEquals(expected, dictee.verbeter());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void uitgebreidGeval() {
|
||||||
|
Dictee dictee = new Dictee("mogelike drangken zijn water cola fruitsap",
|
||||||
|
"Mogelijke dranken zijn: water, cola, fruitsap.");
|
||||||
|
|
||||||
|
assertEquals(13, dictee.verbeter());
|
||||||
|
}
|
||||||
|
|
||||||
|
@ParameterizedTest
|
||||||
|
@ValueSource(strings = { "kat|kat|0", "kot|kat|2" })
|
||||||
|
public void basisGevallen_zelfdeGrootte(String input) {
|
||||||
|
Dictee dictee = createDictee(input);
|
||||||
|
int expected = getExpected(input);
|
||||||
|
|
||||||
|
assertEquals(expected, dictee.verbeter());
|
||||||
|
}
|
||||||
|
|
||||||
|
@ParameterizedTest
|
||||||
|
@ValueSource(strings = { "kast|kat|2", "at|kat|2", "kat|at|2" })
|
||||||
|
public void verschillenInGrootte(String input) {
|
||||||
|
Dictee dictee = createDictee(input);
|
||||||
|
int expected = getExpected(input);
|
||||||
|
|
||||||
|
assertEquals(expected, dictee.verbeter());
|
||||||
|
}
|
||||||
|
|
||||||
|
@ParameterizedTest
|
||||||
|
@ValueSource(strings = { "kat|Kat|1", "Kat|kat|1", "Kat|lat|2", "lat|Kat|2" })
|
||||||
|
public void hoofdletters(String input) {
|
||||||
|
Dictee dictee = createDictee(input);
|
||||||
|
int expected = getExpected(input);
|
||||||
|
|
||||||
|
assertEquals(expected, dictee.verbeter());
|
||||||
|
}
|
||||||
|
|
||||||
|
private int getExpected(String input) {
|
||||||
|
return Integer.parseInt(input.split("\\|")[2]);
|
||||||
|
}
|
||||||
|
|
||||||
|
private Dictee createDictee(String input) {
|
||||||
|
String[] split = input.split("\\|");
|
||||||
|
return new Dictee(split[0], split[1]);
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue