Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sdkjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
sdkjs
Commits
a39940f5
Commit
a39940f5
authored
7 years ago
by
GoshaZotov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add tests for DECIMAL function
parent
26f7b13c
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
cell/.unit-tests/FormulaTests.js
cell/.unit-tests/FormulaTests.js
+14
-0
No files found.
cell/.unit-tests/FormulaTests.js
View file @
a39940f5
...
...
@@ -902,6 +902,20 @@ $( function () {
strictEqual
(
oParser
.
calculate
().
getValue
(),
"
#NUM!
"
,
'
COMBINA(10,-3)
'
);
}
);
test
(
"
Test:
\"
DECIMAL
\"
"
,
function
()
{
oParser
=
new
parserFormula
(
'
DECIMAL("FF",16)
'
,
"
A1
"
,
ws
);
ok
(
oParser
.
parse
(),
'
DECIMAL("FF",16)
'
);
strictEqual
(
oParser
.
calculate
().
getValue
(),
255
,
'
DECIMAL("FF",16)
'
);
oParser
=
new
parserFormula
(
'
DECIMAL(111,2)
'
,
"
A1
"
,
ws
);
ok
(
oParser
.
parse
(),
'
DECIMAL(111,2)
'
);
strictEqual
(
oParser
.
calculate
().
getValue
(),
7
,
'
DECIMAL(111,2)
'
);
oParser
=
new
parserFormula
(
'
DECIMAL("zap",36)
'
,
"
A1
"
,
ws
);
ok
(
oParser
.
parse
(),
'
DECIMAL("zap",36)
'
);
strictEqual
(
oParser
.
calculate
().
getValue
(),
45745
,
'
DECIMAL("zap",36)
'
);
}
);
test
(
"
Test:
\"
ARABIC('LVII')
\"
"
,
function
()
{
oParser
=
new
parserFormula
(
'
ARABIC("LVII")
'
,
"
A1
"
,
ws
);
ok
(
oParser
.
parse
()
);
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment