Skip to content

Commit

Permalink
Change ANG to XCG for CW and SX (#153)
Browse files Browse the repository at this point in the history
  • Loading branch information
jodastephen authored Mar 8, 2025
1 parent d0497f0 commit d07b2a3
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 4 deletions.
6 changes: 5 additions & 1 deletion src/changes/changes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@

<!-- types are add, fix, remove, update -->
<release version="2.0.1" date="SNAPSHOT" description="Version 2.0.1">
<action dev="jodastephen" type="add" issue="150">
Change currency for CW and SX from ANG to XCG. (ISO 4217 Amendment 176).
This change is effective from 31st March 2025.
</action>
<action dev="jodastephen" type="add" issue="147">
Include proguard rule.
</action>
Expand All @@ -21,7 +25,7 @@
</release>
<release version="1.0.5" date="2024-08-25" description="Version 1.0.5">
<action dev="jodastephen" type="update">
Change currency for ZW from ZWL to ZWG. (ISO 4217 Amendment 177)
Change currency for ZW from ZWL to ZWG. (ISO 4217 Amendment 177).
</action>
<action dev="jodastephen" type="update">
Return 'XXX' as the currency symbol for 'XXX' on Java 21.
Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/org/joda/money/CountryData.csv
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ CO,COP # Special: COU
CR,CRC
CU,CUP # Special: CUC
CV,CVE
CW,ANG
CW,XCG
CX,AUD
CY,EUR
CZ,CZK
Expand Down Expand Up @@ -211,7 +211,7 @@ SR,SRD
SS,SSP
ST,STN
SV,SVC
SX,ANG
SX,XCG
SY,SYP
SZ,SZL
TC,USD
Expand Down
3 changes: 2 additions & 1 deletion src/main/resources/org/joda/money/CurrencyData.csv
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ AED,784,2
AFN,971,2
ALL,8,2
AMD,51,2
ANG,532,2
ANG,532,2 # Old, now XCG
AOA,973,2
ARS,32,2
ATS,40,2 # Old, now EUR
Expand Down Expand Up @@ -193,6 +193,7 @@ XBB,956,-1
XBC,957,-1
XBD,958,-1
XCD,951,2
XCG,532,2
XDR,960,-1
XEU,954,-1 # Old, now EUR
XFU,-1,-1 # Old, now EUR
Expand Down
6 changes: 6 additions & 0 deletions src/test/java/org/joda/money/TestCurrencyUnit.java
Original file line number Diff line number Diff line change
Expand Up @@ -441,6 +441,12 @@ void test_factory_ofCountry_String_unknownCurrency() {
.withMessage("No currency found for country 'gb'");
}

@Test
void test_cw_sx_xcg() {
assertThat(CurrencyUnit.ofCountry("CW").getCode()).isEqualTo("XCG");
assertThat(CurrencyUnit.ofCountry("SX").getCode()).isEqualTo("XCG");
}

//-----------------------------------------------------------------------
// Serialisation
//-----------------------------------------------------------------------
Expand Down

0 comments on commit d07b2a3

Please sign in to comment.