close Warning: Can't synchronize with repository "(default)" (The repository directory has changed, you should resynchronize the repository with: trac-admin $ENV repository resync '(default)'). Look in the Trac log for more information.

Changeset 4528 for branches


Ignore:
Timestamp:
2016-06-17T18:32:12-07:00 (8 years ago)
Author:
Marek Rychlik
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/f4grobner/5am-poly-sugar.lisp

    r4526 r4528  
    5050(test sugar-basic
    5151  "Add sugar to a polynomial"
    52   (let* ((p (change-class (string->poly "x*y+x^3" '(x y)) 'poly-with-sugar)))
     52  (let ((p (change-class (string->poly "x*y+x^3" '(x y)) 'poly-with-sugar)))
    5353    (is (= (sugar-value p) 3))))
     54
     55(test sugar-add
     56  "Checks sugar addition rule"
     57  (let* ((p (change-class (string->poly "x*y+x^3" '(x y)) 'poly-with-sugar))
     58         (q (add p p)))
     59    (is (= (sugar-value q) 3))))
     60
     61(test sugar-multiply
     62  "Checks sugar multiplication rule"
     63  (let* ((p (change-class (string->poly "x*y+x^3" '(x y)) 'poly-with-sugar))
     64         (q (multiply p p)))
     65    (is (= (sugar-value q) 6))))
    5466         
    5567(run! 'poly-sugar-suite)
Note: See TracChangeset for help on using the changeset viewer.