Skip to content

Commit

Permalink
Merge pull request #214 from translationCoreApps/enhancement/joel/pro…
Browse files Browse the repository at this point in the history
…gress-api

Adds api methods for use in the tools card
  • Loading branch information
da1nerd authored Jan 11, 2019
2 parents 0c2d0d9 + 96480c5 commit ff49169
Show file tree
Hide file tree
Showing 13 changed files with 2,020 additions and 1,824 deletions.
1 change: 1 addition & 0 deletions __tests__/__fixtures__/basicProps.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"tc": {
"selectedToolName": "translationWords",
"currentLanguage": {
"code": "en_US",
"name": "English",
Expand Down
32 changes: 16 additions & 16 deletions __tests__/settingsHelper.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ const bibles = {
describe('settingsHelper.loadCorrectPaneSettings', () => {
test('Should change the pane settings to render English ULT if Enslish is selected as the GL', () => {
const props = {
toolsReducer: {
currentToolName: 'translationWords'
tc: {
selectedToolName: 'translationWords'
},
projectDetailsReducer: {
currentProjectToolsSelectedGL: {
Expand Down Expand Up @@ -46,8 +46,8 @@ describe('settingsHelper.loadCorrectPaneSettings', () => {

test('Should change the pane settings to render Hindi ULB if Hindi is selected as the GL', () => {
const props = {
toolsReducer: {
currentToolName: 'translationWords'
tc: {
selectedToolName: 'translationWords'
},
projectDetailsReducer: {
currentProjectToolsSelectedGL: {
Expand Down Expand Up @@ -90,8 +90,8 @@ describe('settingsHelper.loadCorrectPaneSettings', () => {
},
];
const props = {
toolsReducer: {
currentToolName: 'translationWords'
tc: {
selectedToolName: 'translationWords'
},
projectDetailsReducer: {
currentProjectToolsSelectedGL: {
Expand All @@ -114,8 +114,8 @@ describe('settingsHelper.loadCorrectPaneSettings', () => {

test('Should render the English ULT if the pane settings is empty and English is selected as the GL', () => {
const props = {
toolsReducer: {
currentToolName: 'translationWords'
tc: {
selectedToolName: 'translationWords'
},
projectDetailsReducer: {
currentProjectToolsSelectedGL: {
Expand Down Expand Up @@ -147,8 +147,8 @@ describe('settingsHelper.loadCorrectPaneSettings', () => {

test('Should render the Hindi ULB if the pane settings is empty and Hindi is selected as the GL', () => {
const props = {
toolsReducer: {
currentToolName: 'translationWords'
tc: {
selectedToolName: 'translationWords'
},
projectDetailsReducer: {
currentProjectToolsSelectedGL: {
Expand Down Expand Up @@ -181,8 +181,8 @@ describe('settingsHelper.loadCorrectPaneSettings', () => {

test('Should render the English ULT if the pane settings is empty and English is selected as the GL', () => {
const props = {
toolsReducer: {
currentToolName: 'translationWords'
tc: {
selectedToolName: 'translationWords'
},
projectDetailsReducer: {
currentProjectToolsSelectedGL: {
Expand Down Expand Up @@ -214,8 +214,8 @@ describe('settingsHelper.loadCorrectPaneSettings', () => {

test('Should add the English ULT and target language in a fresh install if English is selected as the GL', () => {
const props = {
toolsReducer: {
currentToolName: 'translationWords'
tc: {
selectedToolName: 'translationWords'
},
projectDetailsReducer: {
currentProjectToolsSelectedGL: {
Expand Down Expand Up @@ -243,8 +243,8 @@ describe('settingsHelper.loadCorrectPaneSettings', () => {

test('Should add the Hindi ULB and target language in a fresh install if Hindi is selected as the GL', () => {
const props = {
toolsReducer: {
currentToolName: 'translationWords'
tc: {
selectedToolName: 'translationWords'
},
projectDetailsReducer: {
currentProjectToolsSelectedGL: {
Expand Down
Loading

0 comments on commit ff49169

Please sign in to comment.