UNPKG

@ciao-lang/ts-ciao-interface

Version:

Simple Ciao interface for node.

3 lines 9.27 kB
<!DOCTYPE HTML><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="theme-color" content="#273f79"/><link rel="stylesheet" href="lpdoc.css" type="text/css"/><script type="text/javascript" src="lpdoc.js"></script><title>Testing your changes &mdash; </title></head><body><div class="lpdoc-page fixleftbar"><a href="#" id="sidebar-toggle-button" class="lpdoc-navbutton"><span id="sidebar-button-arrow">&#9776;</span></a><div id="sidebar" class="lpdoc-sidebar"><div style="height: 40px; margin-left: auto; margin-right: auto"><img src="ciao-grimoire-128h_autofig.png" width=auto height=100%></div><div class="lpdoc-nav"><span class="lpdoc-on-right"><a class="lpdoc-navbutton" href="CiaoDevel.html">&#x2191;</a><a class="lpdoc-navbutton" href="GitWorkflow.html">&#x2190;</a><a class="lpdoc-navbutton" href="CodeReviews.html">&#x2192;</a><a class="lpdoc-navbutton" href="CiaoDevelsearch.html">&#x1F50D;</a></span><span><a href="CiaoDevelfulltoc.html">TOC</a></span></div><hr></hr><ul class="lpdoc-itemize-sectpath"><li><a href="CiaoDevel.html">CiaoDevel Reference Manual</a> &raquo;<br/> </li><li><a href=""><strong>Testing your changes</strong></a></li></ul><hr></hr><em>ON THIS PAGE</em><ul><li><a href="#Testing your changes">Testing your changes</a></li><li><a href="#Testing documentation">Testing documentation</a></li><li><a href="#Generating and testing distributions">Generating and testing distributions</a></li><ul><li><a href="#Generating a distribution">Generating a distribution</a></li><li><a href="#Testing a distribution">Testing a distribution</a></li></ul></ul></div><div class="lpdoc-main"><div id=""><h1>Testing your changes</h1><a class="lpdoc-idx-anchor" href="CiaoDevelsearch.html#TestChanges"></a> <strong>Author(s):</strong> <a class="lpdoc-idx-anchor" id="The Ciao Development Team" href="CiaoDevelsearch.html#The Ciao Development Team">The Ciao Development Team</a>.<p> <div id="Testing your changes"><h2>Testing your changes</h2> After you make any changes please check thoroughly that nothing has stopped working. Specifically,<p><ul> <li>Make sure that the documentation is up-to-date and correctly generated. <li>Verify that new features have their associated tests. <li>Run automated tests (<tt>ciao test</tt>). <li>Run other tests in the <tt>testsuite</tt> bundle. <li>Try out, to the extent possible, examples and code without automated tests, as well as tests from third-party code that depends on Ciao. </ul> </div><div id="Testing documentation"><h2>Testing documentation</h2> The documentation should be as complete and correct as possible. Please check that every change you do can be documented (introducing syntactic errors is easy). In order to generate the documentation:<p><ul> <li>Make sure that there are no (new) error/warnings in the output of <tt>ciao build --docs</tt> <li>Verify that the documentation has been generated correctly. It should appear under <tt>&lt;CIAODIR&gt;/build/doc</tt> in <tt>.info</tt>, <tt>.pdf</tt>, and HTML formats. Have a look at it, verify that the links (in info and HTML formats) are not dead. <li>Check that every library in the distribution has a well-formed manual page. A component should appear here iff it goes into the distribution; otherwise the documentation will be out of sync with respect to the distribution. </ul> </div><div id="Generating and testing distributions"><h2>Generating and testing distributions</h2> See the <tt>ciao-distro-tools</tt> bundle to learn how we produce <em>multirepostory</em> source distributions from the development <em>monorepository</em>.<p><div id="Generating a distribution"><h3>Generating a distribution</h3> <tt>ciao</tt> (super-command) offers some commands to generate packaged bundles for several platforms with the command <tt>gen_pbundle --kind=Kind</tt>, where <span class="lpdoc-var">Kind</span> is one of:<p><ul> <li><tt>win32</tt>: Creates a Windows installer. <li><tt>rpm [--option=value...]</tt>: Creates an <span class="lpdoc-var">RPM</span> package. For more details please read the documentation for the <tt>gen_pbundle --kind=rpm</tt> module. One or more options may be added; main ones are:<p><dl> <dt><tt>vendor_independent=yes</tt><dd> Creates packages that should work in all mainstream <span class="lpdoc-var">RPM</span> Linux distributions. This is the default. If disabled, packages are only guaranteed to work in the same distribution (vendor) they were generated for. </dl> <li><tt>bin</tt>: Creates the binary packages (using <tt>gz</tt> and <tt>bzip2</tt>). <li><tt>bin_tgz</tt>: Creates the binary package compressed using <tt>gz</tt>. <li><tt>bin_tbz</tt>: Creates the binary package compressed using <tt>bzip2</tt>. <li><tt>src</tt>: Creates the <tt>tar</tt> packages in <tt>gz</tt> and <tt>bzip2</tt> compressed formats. <li><tt>tgz</tt>: Creates the <tt>tar</tt> packages in <tt>gz</tt> compressed format. <li><tt>tbz</tt>: Creates the <tt>tar</tt> packages in <tt>bzip2</tt> compressed format. </ul> <div class="lpdoc-note"> <strong>Note:</strong> distribution generation may ignore some files under the source tree based on some marks (<span class="lpdoc-var">NOCOMPILE</span>, <span class="lpdoc-var">NODISTRIBUTE</span>, <span class="lpdoc-var">NOINSTALL</span>, etc.). See a more complete description of at <a class="lpdoc-idx-anchor" id="0" href="CiaoDevelsearch.html#library(source_tree)"><tt>library(source_tree)</tt></a>. </div> <p></div><div id="Testing a distribution"><h3>Testing a distribution</h3> Distributions should be installed and tested in clean environments. Ideally, this means using a machine with no Ciao installed. Otherwise, you should clear your environment variables of any trace of paths and environment variables pointing to Ciao stuff. &apos;which ciao&apos; will point to executables -- remove from <span class="lpdoc-var">PATH</span> the corresponding paths. Any environment variable starting by <span class="lpdoc-var">CIAO</span> (<tt>env | grep CIAO</tt>) should also be removed prior to compilation.<p>We <strong>must</strong> compile and test in all supported architectures.<p>Perform the installation <strong>exactly</strong> as it is stated in the <span class="lpdoc-var">INSTALLATION</span> file.<p>For global installations, compile and install under a user and test with another user, in order to make sure that everything gets compiled and needed. You can make the installation as root and the testing as yourself. Make sure every step of the installation works.<p>Some (OS-specific) additional tests:<p><ul> <li>Compile and run the tests, and check that everything works. <li>All commands (<tt>ciao</tt>, <tt>ciaosh</tt>, <tt>ciaoc</tt>, etc.) must be reachable and they must belong to the distribution we have installed. <li>Windows: from windows file explorer: check left-button menus<p><ul> <li><tt>.pl</tt> files: load <tt>foo.pl</tt> into top-level shell and make executable (must generate <tt>foo.bat</tt> and <tt>foo.cpx</tt> files) <li><tt>.bat</tt> and <tt>.cpx</tt> generated files: double-click on them and check that foo program works </ul> <li>Unix-like systems:<p><ul> <li>The <tt>ciao-env</tt> command should be patched with valid paths (it is used from the shell initialization files). <li>Check that the info file works well. This can be done executing <tt>info</tt> and verifying that an info entry for Ciao has been placed, and also running <tt>info ciao</tt>. It should also be visible with <tt>M-x info</tt> from emacs. <li>Execute <tt>man ciao</tt> to check that the man page has been generated and configured successfully. <li><tt>ciao doc BUNDLE</tt> should open the HTML manuals for BUNDLE <li><tt>.pdf</tt> files must also be in place. </ul> </ul> Other tests specific to the Emacs Mode:<p><ul> <li>Verify (<tt>C-h i</tt>) that the Ciao info files <em>for the version you installed</em> are visible. <li>Load <tt>&lt;CIAODIR&gt;/examples/hw.pl</tt>, check that buffer coloring works (substitute the Ciao path by the directory where the sources you dowloaded are). <li>Check that the Ciao menu options and tool bar appear on top of Emacs window. <li><tt>C-c l</tt> to load the file into Ciao top-level and call <a class="lpdoc-idx-anchor" id="1" href="CiaoDevelsearch.html#main/1"><tt>main/1</tt></a> to check basic top-level functionality. <li>Put the cursor over <a class="lpdoc-idx-anchor" id="2" href="CiaoDevelsearch.html#write/1"><tt>write/1</tt></a> and hit <tt>C-c tab</tt> to go to the Ciao documentation (in info format). <li>Load <tt>hw.pl</tt> in debug mode (<tt>C-c d</tt>), run <a class="lpdoc-idx-anchor" id="3" href="CiaoDevelsearch.html#main/1"><tt>main/1</tt></a>, go through the execution until its end. <li>Move the cursor to last line of <a class="lpdoc-idx-anchor" id="4" href="CiaoDevelsearch.html#main/0"><tt>main/0</tt></a>, and do <tt>C-c S b</tt> to check breakpoints. Run <a class="lpdoc-idx-anchor" id="5" href="CiaoDevelsearch.html#main/1"><tt>main/1</tt></a> again, and press <tt>l</tt> to check that the execution stops at the correct program point. </ul> </div></div><br/></div><div class="lpdoc-footer">Generated with LPdoc using Ciao</div></div><div class="lpdoc-clearer"></div></div></body></html>