Repository: joke2k/faker

Issue:
Norwegian ssn returns the wrong format for the date part 
SSN for no_NO returns the wrong format of the date part.

### Steps to reproduce

As @cloveras pointed out:
Using December 31 1999 as the date of birth (YYYYMMDD):
ssn('19991231','M')

This results in SSNs like these:
99123145123
99123108724
99123127532

### Expected behavior

The correct format is DDMMYY.

### Actual behavior

These start with the date of birth in YYMMDD format.


Discussion:

Patch:
diff --git a/faker/providers/ssn/no_NO/__init__.py b/faker/providers/ssn/no_NO/__init__.py
index 207831b8..2f171d42 100644
--- a/faker/providers/ssn/no_NO/__init__.py
+++ b/faker/providers/ssn/no_NO/__init__.py
@@ -71,7 +71,7 @@ class Provider(SsnProvider):
                 gender_num = self.generator.random.choice((0, 2, 4, 6, 8))
             elif gender == 'M':
                 gender_num = self.generator.random.choice((1, 3, 5, 7, 9))
-            pnr = birthday.strftime('%y%m%d') + suffix.zfill(2) + str(gender_num)
+            pnr = birthday.strftime('%d%m%y') + suffix.zfill(2) + str(gender_num)
             pnr_nums = [int(ch) for ch in pnr]
             k1 = checksum(Provider.scale1, pnr_nums)
             k2 = checksum(Provider.scale2, pnr_nums + [k1])


Test patch:
diff --git a/tests/providers/test_ssn.py b/tests/providers/test_ssn.py
index abf33e63..11d88cca 100644
--- a/tests/providers/test_ssn.py
+++ b/tests/providers/test_ssn.py
@@ -180,9 +180,11 @@ class TestNoNO(unittest.TestCase):
             self.assertEqual(len(ssn), 11)
 
     def test_no_NO_ssn_dob_passed(self):
-        date_of_birth = '20010203'
-        ssn = self.factory.ssn(dob=date_of_birth)
-        self.assertEqual(ssn[:6], date_of_birth[2:])
+        test_data = [('20010203', '030201'),
+                     ('19991231', '311299')]
+        for date_of_birth, expected_dob_part in test_data:
+            ssn = self.factory.ssn(dob=date_of_birth)
+            self.assertEqual(ssn[:6], expected_dob_part)
 
     def test_no_NO_ssn_invalid_dob_passed(self):
         with self.assertRaises(ValueError):