@mchp-mcc/scf-pic8-osc-v1 4.3.1 → 4.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mchp-mcc/scf-pic8-osc-v1",
3
- "version": "4.3.1",
3
+ "version": "4.3.2",
4
4
  "scf": {
5
5
  "reducer": "auto",
6
6
  "creator": "output/creator.js",
@@ -28,6 +28,7 @@
28
28
  },
29
29
  "shouldNotifyOnDeploy": false
30
30
  },
31
+ "jenkinsPipeline": "MCU8_DS_PIPELINE_1XY",
31
32
  "license": "SEE LICENSE IN LICENSE.txt",
32
33
  "scripts": {
33
34
  "build": "gulp build --gulpfile config/gulpfile.js --cwd .",
@@ -47,8 +48,8 @@
47
48
  "build-run-dir-future": "node config/extract-run-directory-future.js",
48
49
  "profile": "jest profile",
49
50
  "release": "yarn build && yarn test && node -e 'require(\"./config/scf-project-scripts\").releaseProject()'",
50
- "test:itf:all": "node ./node_modules/@mchp-mcc/ccl-itf/lib/index.js --sp=./tests/itf --rd=./run",
51
- "test:itf:dev": "node ./node_modules/@mchp-mcc/ccl-itf/lib/index.js --sp=./tests/itf --rd=./run --sf=osc.major.test.ts --df=.*Q43"
51
+ "test:itf:all": "node ./node_modules/@mchp-mcc/ccl-itf/lib/index.js --sp=tests/itf --rd=run --df=\"PIC18F57Q43|PIC16F18877|PIC16LF18875|PIC18F16Q40|PIC18F16Q41|PIC18F47Q10\"",
52
+ "test:itf:dev": "node ./node_modules/@mchp-mcc/ccl-itf/lib/index.js --sp=tests/itf --rd=run --sf=osc.major.test.ts --df=\"PIC18F57Q43|PIC16F18877|PIC16LF18875|PIC18F16Q40|PIC18F16Q41|PIC18F47Q10\""
52
53
  },
53
54
  "husky": {
54
55
  "hooks": {
@@ -69,9 +70,6 @@
69
70
  "type": "git",
70
71
  "url": "git+ssh://git@https://bitbucket.microchip.com/scm/cc8scrip/scf-pic8-osc-v1.git"
71
72
  },
72
- "publishConfig": {
73
- "registry": "https://artifacts.microchip.com/artifactory/api/npm/npm/"
74
- },
75
73
  "jest": {
76
74
  "testPathIgnorePatterns": [
77
75
  "/node_modules/",
@@ -84,7 +82,15 @@
84
82
  "<rootDir>/run"
85
83
  ],
86
84
  "preset": "ts-jest",
87
- "collectCoverage": true
85
+ "collectCoverage": true,
86
+ "coverageThreshold": {
87
+ "./src": {
88
+ "branches": 80,
89
+ "functions": 80,
90
+ "lines": 80,
91
+ "statements": 80
92
+ }
93
+ }
88
94
  },
89
95
  "dependencies": {
90
96
  "@microchip/api-prefix-registration": "^0.1.0",
@@ -96,7 +102,8 @@
96
102
  "@microchip/scf-device": "^8.2.0",
97
103
  "@microchip/scf-integration-test": "^1.0.0",
98
104
  "@microchip/scf-interface": "^1.4.0",
99
- "@microchip/scf-register-view-helper": "^2.4.0"
105
+ "@microchip/scf-register-view-helper": "^2.4.0",
106
+ "babel-jest": "^27.0.6"
100
107
  },
101
108
  "devDependencies": {
102
109
  "@babel/core": "^7.9.6",
@@ -105,8 +112,8 @@
105
112
  "@babel/preset-react": "^7.9.4",
106
113
  "@babel/preset-typescript": "^7.9.0",
107
114
  "@mchp-mcc/avr-8bit": "^4.2.6",
108
- "@mchp-mcc/ccl-itf": "^0.2.11",
109
- "@mchp-mcc/pic-8bit": "^5.4.1",
115
+ "@mchp-mcc/ccl-itf": "^0.2.13",
116
+ "@mchp-mcc/pic-8bit": "^5.4.5-dev2",
110
117
  "@mchp-mcc/pic-8bit-types": "^5.4.1",
111
118
  "@microchip/config-device": "^1.1.1",
112
119
  "@microchip/initializer-system": "^0.5.4",
@@ -114,9 +121,9 @@
114
121
  "@microchip/osc-clocks": "^0.2.0",
115
122
  "@microchip/pic-8bit-types": "^5.0.1",
116
123
  "@microchip/pin-standard": "^0.2.14",
117
- "@microchip/run-directory": "^2.4.14",
124
+ "@microchip/run-directory": "^2.4.28",
118
125
  "@microchip/run-directory-future": "^1.1.17",
119
- "@microchip/scf-automodule": "^4.14.2",
126
+ "@microchip/scf-automodule": "^4.14.5",
120
127
  "@microchip/scf-autoview": "^3.17.0",
121
128
  "@microchip/scf-project-scripts": "^1.0.0",
122
129
  "@microchip/scf-server": "^1.5.10",
@@ -149,13 +156,13 @@
149
156
  "hard-source-webpack-plugin": "^0.13.1",
150
157
  "husky": "^4.2.4",
151
158
  "is-wsl": "^2.1.0",
152
- "jest": "^24.8.0",
159
+ "jest": "^27.0.6",
153
160
  "jest-html-reporter": "^2.5.0",
154
161
  "jest-pnp-resolver": "^1.2.1",
155
162
  "lint-staged": "^10.1.3",
156
163
  "pnp-webpack-plugin": "^1.5.0",
157
164
  "prettier": "^2.0.5",
158
- "ts-jest": "^24.0.2",
165
+ "ts-jest": "^27.0.3",
159
166
  "ts-pnp": "^1.1.2",
160
167
  "typescript": "^4.0.5",
161
168
  "webpack": "^4.34.0",
@@ -1,4 +1,5 @@
1
1
  import { ClockCalculator } from "./ClockCalculator";
2
+ import { StringConstants } from "./StringConstants";
2
3
 
3
4
  describe("Osc Calculations", () => {
4
5
  // jest cases for system oscillator calculations
@@ -58,4 +59,59 @@ describe("Osc Calculations", () => {
58
59
  ).getCurrentSystemClk(),
59
60
  ).toBe(17000000);
60
61
  });
62
+
63
+ it("Test case 8: oscSelect = SOSC, HFInternalClk = 4_MHz, externalClk = 17000000Hz, clkDevider = 1", () => {
64
+ expect(
65
+ new ClockCalculator(
66
+ StringConstants.SOSC,
67
+ "4_MHz",
68
+ 17000000,
69
+ 1,
70
+ ).getCurrentSystemClk(),
71
+ ).toBe(32768);
72
+ });
73
+
74
+ it("Test case 9: oscSelect = HFINTOSC_2xPLL, HFInternalClk = 4_MHz, externalClk = 17000000Hz, clkDevider = 1", () => {
75
+ expect(
76
+ new ClockCalculator(
77
+ StringConstants.HFINTOSC_2xPLL,
78
+ "4_MHz",
79
+ 17000000,
80
+ 1,
81
+ ).getCurrentSystemClk(),
82
+ ).toBe(4000000);
83
+ });
84
+
85
+ it("Test case 10: oscSelect = EXTOSC, HFInternalClk = 4_MHz, externalClk = 170000Hz, clkDevider = 1", () => {
86
+ expect(
87
+ new ClockCalculator(
88
+ StringConstants.EXTOSC,
89
+ "4_MHz",
90
+ 17000000,
91
+ 1,
92
+ ).getCurrentSystemClk(),
93
+ ).toBe(17000000);
94
+ });
95
+
96
+ it("Test case 11: oscSelect = EXTOSC, HFInternalClk = 4_MHz, externalClk = 17000000Hz, clkDevider = 1", () => {
97
+ expect(
98
+ new ClockCalculator(
99
+ StringConstants.EXTOSC,
100
+ "4_MHz",
101
+ 17000000,
102
+ 1,
103
+ ).getCurrentSystemClk(),
104
+ ).toBe(17000000);
105
+ });
106
+
107
+ it("Test case 12: oscSelect = HFINTOSC_2xPLL, HFInternalClk = 4_MHz, externalClk = 17000000Hz, clkDevider = 1", () => {
108
+ expect(
109
+ new ClockCalculator(
110
+ StringConstants.HFINTOSC_2xPLL,
111
+ "8_MHz",
112
+ 17000000,
113
+ 1,
114
+ ).getCurrentSystemClk(),
115
+ ).toBe(16000000);
116
+ });
61
117
  });