All language subtitles for 389 Completing the formatting tests.en

af Afrikaans
ak Akan
sq Albanian
am Amharic
hy Armenian
az Azerbaijani
eu Basque
be Belarusian
bem Bemba
bn Bengali
bh Bihari
bs Bosnian
br Breton
bg Bulgarian
km Cambodian
ca Catalan
ceb Cebuano
chr Cherokee
ny Chichewa
zh-CN Chinese (Simplified)
zh-TW Chinese (Traditional)
co Corsican
hr Croatian
cs Czech
da Danish
nl Dutch
en English
eo Esperanto
et Estonian
ee Ewe
fo Faroese
tl Filipino
fi Finnish
fr French
fy Frisian
gaa Ga
gl Galician
ka Georgian
de German
el Greek
gn Guarani
gu Gujarati
ht Haitian Creole
ha Hausa
haw Hawaiian
iw Hebrew
hi Hindi
hmn Hmong
hu Hungarian
is Icelandic
ig Igbo
id Indonesian
ia Interlingua
ga Irish
it Italian
ja Japanese
jw Javanese
kn Kannada
kk Kazakh
rw Kinyarwanda
rn Kirundi
kg Kongo
ko Korean
kri Krio (Sierra Leone)
ku Kurdish
ckb Kurdish (Soranรฎ)
ky Kyrgyz
lo Laothian
la Latin
lv Latvian
ln Lingala
lt Lithuanian
loz Lozi
lg Luganda
ach Luo
lb Luxembourgish
mk Macedonian
mg Malagasy
ms Malay
ml Malayalam
mt Maltese
mi Maori
mr Marathi
mfe Mauritian Creole
mo Moldavian
mn Mongolian
my Myanmar (Burmese)
sr-ME Montenegrin
ne Nepali
pcm Nigerian Pidgin
nso Northern Sotho
no Norwegian
nn Norwegian (Nynorsk)
oc Occitan
or Oriya
om Oromo
ps Pashto
pl Polish
pt-BR Portuguese (Brazil)
pt Portuguese (Portugal)
pa Punjabi
qu Quechua
ro Romanian
rm Romansh
nyn Runyakitara
ru Russian
sm Samoan
gd Scots Gaelic
sr Serbian
sh Serbo-Croatian
st Sesotho
tn Setswana
crs Seychellois Creole
sn Shona
sd Sindhi
si Sinhalese
sk Slovak
sl Slovenian
so Somali
es Spanish
es-419 Spanish (Latin American)
su Sundanese
sw Swahili
sv Swedish
tg Tajik
ta Tamil
tt Tatar
te Telugu
th Thai
ti Tigrinya
to Tonga
lua Tshiluba
tum Tumbuka
tr Turkish
tk Turkmen
tw Twi
ug Uighur
uk Ukrainian
ur Urdu
uz Uzbek
vi Vietnamese
cy Welsh
wo Wolof
xh Xhosa
yi Yiddish
yo Yoruba
zu Zulu

Original subtitles

In this video we are going to add some more tests for the remaining metals in this class.

And the next method that we want to focus on is the day of the week.

So for this method we are going to create a new group called Day of Week with G.B. locale.

And then we can create a group body and then we are going to copy paste the setup matlab and the first

test from the previous group and then we are going to adjust the first name to be Monday and we're going

to make sure that we call format that day of week and that the expectation is the first three letters

of Monday because this is a short format of the day of the week.

And then we can run the tests once again and as we can see we get a success.

OK.

So now that we have this we could duplicate this group and test for example the same method but with

a different locale.

So here I could put a day a week but this time with the Italian locale and here I could change the default

locale to I.T. on the score 90 and then I could change that description to unity which is the Italian

for Monday and I can change the expectation to l you.

And we would be what we expect.

So I can run the tests one more time and as we can see the tests pass for the Italian locale as well.

Moving on we could add some tests for the currency method so we could add a new group called currency.

And this time for example with U S local and then I could add the group body and in here I can now set

setup method and inside here I could said i n the l don't default to look out to and on the score U

S like this.

And because in this case we are not doing date for month and thus then I don't need to initialize date

formatting so I can go straight on to writing the test.

And just to make my life a bit quicker I'm going to copy these three tests from the hours group and

I went to paste them into here and then I can update the expectations to ensure that we go form up the

currency and here rather than 10 hours what we want to print is dollar number 10.

Like this.

And the second test will expect format the currency of zero to be an empty string.

Because this is how this method is implemented.

And finally we can implement the last test with minus five.

And in this case we expect to see minus and then $ 5 like this.

OK.

So we have learned about testing code that does no date and currency formatting and adding more tests

at this point would become repetitive because it is just about setting up a locale and writing the correct

expectations.

So at this stage I can run all the tests for this file and I can see that they are all green.

So we can continue on the next video.

Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.